aniketpanjwani / chomper

Internet blocker for the Linux desktop.
https://addictedto.tech/chomper/
GNU General Public License v3.0
356 stars 43 forks source link

Long commands (>999 characters) don't get written to crontab. #27

Open aniketpanjwani opened 6 years ago

aniketpanjwani commented 6 years ago
Steps to reproduce the problem:
  1. Have a PATH variable sufficiently long so that the reset_command variable in set_block_length in ./chomper/block.py is more than 999 characters.
  2. Run chomper.
  3. Look at root crontab - reset_command will not be written to root's crontab.
Any other comments? What have you tried so far?

I was confused about why the cron jobs suddenly stopped working. It turns out this is due to my adding more things to my PATH variable. For now, I'm going to prune my PATH variable of unnecessary things, but there should be a better way of putting the normal user's PATH variable in the root user's environment.

System information

Operating system: (e.g. Linux Mint 18)