mirror of
https://github.com/cheat/cheat.git
synced 2025-09-04 02:58:29 +02:00
Compare commits
8 Commits
Author | SHA1 | Date | |
---|---|---|---|
3be95142ed | |||
bb324e94a4 | |||
7084ce2f45 | |||
905006f09c | |||
06a368fb1f | |||
6a9422502a | |||
41332f1d8a | |||
a3c682729e |
@ -38,7 +38,7 @@ from docopt import docopt
|
|||||||
|
|
||||||
if __name__ == '__main__':
|
if __name__ == '__main__':
|
||||||
# parse the command-line options
|
# parse the command-line options
|
||||||
options = docopt(__doc__, version='cheat 2.1.24')
|
options = docopt(__doc__, version='cheat 2.1.25')
|
||||||
|
|
||||||
# list directories
|
# list directories
|
||||||
if options['--directories']:
|
if options['--directories']:
|
||||||
|
@ -14,7 +14,9 @@ SHELL=/bin/bash
|
|||||||
# example entries
|
# example entries
|
||||||
# every 15 min
|
# every 15 min
|
||||||
*/15 * * * * /home/user/command.sh
|
*/15 * * * * /home/user/command.sh
|
||||||
|
|
||||||
# every midnight
|
# every midnight
|
||||||
0 * * * * /home/user/command.sh
|
* 0 * * * /home/user/command.sh
|
||||||
|
|
||||||
# every Saturday at 8:05 AM
|
# every Saturday at 8:05 AM
|
||||||
5 8 * * 6 /home/user/command.sh
|
5 8 * * 6 /home/user/command.sh
|
||||||
|
@ -1,5 +1,8 @@
|
|||||||
# Print date in format suitable for affixing to file names
|
# Print date in format suitable for affixing to file names
|
||||||
date +"%Y%m%d_%H%M%S"
|
date +"%Y%m%d_%H%M%S"
|
||||||
|
|
||||||
# Convert Unix timestamp to Date
|
# Convert Unix timestamp to Date(Linux)
|
||||||
date -d @1440359821
|
date -d @1440359821
|
||||||
|
|
||||||
|
# Convert Unix timestamp to Date(Mac)
|
||||||
|
date -r 1440359821
|
||||||
|
11
cheat/cheatsheets/ncdu
Normal file
11
cheat/cheatsheets/ncdu
Normal file
@ -0,0 +1,11 @@
|
|||||||
|
# Save results to file
|
||||||
|
ncdu -o ncdu.file
|
||||||
|
|
||||||
|
# Read from file
|
||||||
|
ncdu -f ncdu.file
|
||||||
|
|
||||||
|
# Save results to compressed file
|
||||||
|
ncdu -o-| gzip > ncdu.file.gz
|
||||||
|
|
||||||
|
# Read from compressed file
|
||||||
|
zcat ncdu.file.gz | ncdu -f-
|
20
cheat/cheatsheets/svn
Normal file
20
cheat/cheatsheets/svn
Normal file
@ -0,0 +1,20 @@
|
|||||||
|
## update working copy from repository
|
||||||
|
svn update "/path"
|
||||||
|
|
||||||
|
## show changed files in working copy
|
||||||
|
svn status
|
||||||
|
|
||||||
|
## show what changed in local file
|
||||||
|
svn diff "/path/filename"
|
||||||
|
|
||||||
|
## add files or folders
|
||||||
|
svn add "path/item"
|
||||||
|
|
||||||
|
## revert local uncommited changes
|
||||||
|
svn revert "/path/file"
|
||||||
|
|
||||||
|
## commit changes to repo
|
||||||
|
svn commit -m "message" "/path"
|
||||||
|
|
||||||
|
## show help for 'svn diff'
|
||||||
|
svn help diff
|
2
setup.py
2
setup.py
@ -3,7 +3,7 @@ import os
|
|||||||
|
|
||||||
setup(
|
setup(
|
||||||
name = 'cheat',
|
name = 'cheat',
|
||||||
version = '2.1.24',
|
version = '2.1.25',
|
||||||
author = 'Chris Lane',
|
author = 'Chris Lane',
|
||||||
author_email = 'chris@chris-allen-lane.com',
|
author_email = 'chris@chris-allen-lane.com',
|
||||||
license = 'GPL3',
|
license = 'GPL3',
|
||||||
|
Reference in New Issue
Block a user