-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
0 parents
commit 1c3c131
Showing
5 changed files
with
774 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
{ | ||
"todo-tree.tree.scanMode": "workspace only" | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
'general': { | ||
'run_as_root': 0, | ||
'prog_name': '', | ||
'disp_name': '' | ||
}, | ||
|
||
|
||
# check for run as root/need to run as root | ||
run_as_root = self.conf_dict['general']['run_as_root'] | ||
file_name = os.path.basename(__file__) | ||
run_root = (os.geteuid() == 0) | ||
if run_as_root and not run_root: | ||
msg = 'This script needs to be run as root. '\ | ||
f'Try \'sudo ./{file_name}\'' | ||
print(msg) | ||
exit() | ||
elif not run_as_root and run_root: | ||
msg = 'This script should not be run as root. '\ | ||
f'Try \'./{file_name}\'' | ||
print(msg) | ||
exit() |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,27 @@ | ||
{ | ||
"general": { | ||
"prog_name": "SpaceOddity" | ||
}, | ||
"preflight": [ | ||
], | ||
"sys_reqs": [ | ||
], | ||
"py_reqs": [ | ||
"python-crontab" | ||
], | ||
"dirs": [ | ||
"${HOME}/.spaceoddity", | ||
"${HOME}/.config/spaceoddity" | ||
], | ||
"files": { | ||
"spaceoddity.py": "${HOME}/.spaceoddity", | ||
"uninstall.py": "${HOME}/.spaceoddity", | ||
"LICENSE": "${HOME}/.spaceoddity", | ||
"VERSION": "${HOME}/.spaceoddity" | ||
}, | ||
"postflight": [ | ||
"convert_json.py", | ||
"cron_install.py", | ||
"${HOME}/.spaceoddity/spaceoddity.py" | ||
] | ||
} |
Oops, something went wrong.