Skip to content

Commit

Permalink
feat(#77): sys
Browse files Browse the repository at this point in the history
  • Loading branch information
h1alexbel committed Oct 8, 2024
1 parent 4cc29ee commit 2500ef5
Show file tree
Hide file tree
Showing 6 changed files with 32 additions and 8 deletions.
9 changes: 6 additions & 3 deletions cli/src/main.rs
Original file line number Diff line number Diff line change
Expand Up @@ -25,15 +25,18 @@ Fakehub server and storage.
use clap::Parser;
use log::{error, info};

/// System calls.
pub mod sys;

use fakehub_server::Server;

use crate::args::{Args, Command};
use fakehub_server::sys::instance_os::instance_os;
use fakehub_server::sys::kill_unix::kill_unix;
#[cfg(target_os = "windows")]
use std::os::windows::process::CommandExt;
use fakehub_server::sys::current_port::current_port;
use fakehub_server::sys::instance_os::instance_os;
use fakehub_server::sys::sys_info::sys_info;
use crate::sys::current_port::current_port;
use crate::sys::kill_unix::kill_unix;

mod args;

Expand Down
File renamed without changes.
File renamed without changes.
25 changes: 25 additions & 0 deletions cli/src/sys/mod.rs
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
// The MIT License (MIT)
//
// Copyright (c) 2024 Aliaksei Bialiauski
//
// Permission is hereby granted, free of charge, to any person obtaining a copy
// of this software and associated documentation files (the "Software"), to deal
// in the Software without restriction, including without limitation the rights
// to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
// copies of the Software, and to permit persons to whom the Software is
// furnished to do so, subject to the following conditions:
//
// The above copyright notice and this permission notice shall be included
// in all copies or substantial portions of the Software.
//
// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
// FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT. IN NO EVENT SHALL THE
// AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
// OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
// SOFTWARE.
/// Kill UNIX port.
pub mod kill_unix;
/// Current fakehub port.
pub mod current_port;
2 changes: 1 addition & 1 deletion server/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ pub mod handlers;
pub mod objects;
/// Reports.
pub mod report;
/// System.
/// System information.
pub mod sys;
#[allow(unused_imports)]
#[macro_use]
Expand Down
4 changes: 0 additions & 4 deletions server/src/sys/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -21,9 +21,5 @@
// SOFTWARE.
/// Instance OS.
pub mod instance_os;
/// Kill UNIX port.
pub mod kill_unix;
/// System information.
pub mod sys_info;
/// Current fakehub port.
pub mod current_port;

0 comments on commit 2500ef5

Please sign in to comment.