andreasgrill / auto-selfcontrol

Small utility to schedule start and stop times of SelfControl
MIT License
305 stars 37 forks source link

Improved CLI workflow, with bash script and separate config file #29

Closed sbibauw closed 4 years ago

sbibauw commented 6 years ago

I propose to change the default usage of Auto-SelfControl by having a basic bash script ([auto-selfcontrol](auto-selfcontrol)) be the main entry point, and allowing both a easy access to edit config.json (auto-selfcontrol config or auto-selfcontrol edit) and a separate command to activate/install the defined block-schedule (auto-selfcontrol activate or auto-selfcontrol install).

Simultaneously, config.json has been moved to the default configuration dir on mac/unix: /usr/local/etc/ (so /usr/local/etc/auto-selfcontrol/config.json). This allows to update the program without the config file being affected.

More importantly, all these modifications are proposed to allow a very easy and automated installation with Homebrew (a simple brew install auto-selfcontrol). I have already prepared the ruby Formula which does everything (install auto-selfcontrol to /usr/local/bin/, the configuration file to /usr/local/etc/, etc.).

Feel free to cherrypick only what you think is relevant of course.

2ndMessiah commented 5 years ago

Seems the maintainer is not caring about this project anymore? But I think u should have a fork version of your self and make it public :)) Nice enough.

sbibauw commented 5 years ago

Seems the maintainer is not caring about this project anymore? But I think u should have a fork version of your self and make it public :)) Nice enough.

Thanks! It is indeed forked and available, if you want to try it: https://github.com/sbibauw/auto-selfcontrol :-)

I updated the README and created a tap so that others can install with Homebrew too:

brew install --HEAD sbibauw/utils/auto-selfcontrol
andreasgrill commented 4 years ago

Thanks @sbibauw! I've merged your commits in the new version of Auto-SelfControl.