mirror of
https://github.com/CHN-beta/hpcstat.git
synced 2026-01-11 02:09:24 +08:00
some fix
This commit is contained in:
@@ -17,7 +17,7 @@ namespace hpcstat
|
||||
process = std::make_unique<bp::child>
|
||||
(program.string(), bp::args(args), bp::std_out > output, bp::std_err > stderr, bp::std_in < input);
|
||||
input << *stdin;
|
||||
input.close();
|
||||
input.pipe().close();
|
||||
}
|
||||
else process = std::make_unique<bp::child>
|
||||
(program.string(), bp::args(args), bp::std_out > output, bp::std_err > stderr, bp::std_in < bp::null);
|
||||
|
||||
@@ -34,7 +34,7 @@ int main(int argc, const char** argv)
|
||||
if (!signature) return 1;
|
||||
data.Signature = *signature;
|
||||
sql::writedb(data);
|
||||
std::cout << fmt::format("\33[2K\rLogged in as {}.\n", *fp);
|
||||
std::cout << fmt::format("\33[2K\rLogged in as {}.\n", Keys[*fp].Username);
|
||||
}
|
||||
}
|
||||
else if (args[1] == "logout")
|
||||
|
||||
@@ -47,7 +47,7 @@ namespace hpcstat::ssh
|
||||
(
|
||||
std::filesystem::path(*datadir) / "ssh-keygen",
|
||||
{
|
||||
"-Y", "sign",
|
||||
"-Y", "sign", "-q",
|
||||
"-f", fmt::format("{}/keys/{}", *datadir, Keys[fingerprint].PubkeyFilename),
|
||||
"-n", "hpcstat@chn.moe", "-"
|
||||
},
|
||||
|
||||
Reference in New Issue
Block a user