some bugfixes
This commit is contained in:
Binary file not shown.
@@ -1,11 +1,11 @@
|
|||||||
{ pkgs
|
{ pkgs
|
||||||
, ...
|
, ...
|
||||||
}: let
|
}: let
|
||||||
python = pkgs.python3.withPackages (ps: with ps; [pkgs.python311Pacakges.cryptography]);
|
python = pkgs.python3.withPackages (ps: with ps; [pkgs.python311Packages.cryptography]);
|
||||||
python_script = pkgs.writeText (builtins.readFile ./main.py);
|
python_script = pkgs.writeText "main-py" (builtins.readFile ./main.py);
|
||||||
in pkgs.writeShellApplication {
|
in pkgs.writeShellApplication {
|
||||||
name = "yt-block";
|
name = "yt_block";
|
||||||
text = ''
|
text = ''
|
||||||
${python}/bin/python ${python_script}
|
${python}/bin/python ${python_script} "$@"
|
||||||
'';
|
'';
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -67,6 +67,7 @@ def cmd_guard():
|
|||||||
unblock_yt()
|
unblock_yt()
|
||||||
|
|
||||||
# decrement time_current
|
# decrement time_current
|
||||||
|
if state["yt_time_current"] > 0:
|
||||||
state["yt_time_current"] -= 1
|
state["yt_time_current"] -= 1
|
||||||
|
|
||||||
write_state(state, pwd)
|
write_state(state, pwd)
|
||||||
|
|||||||
Reference in New Issue
Block a user