mirror of
https://github.com/cheat/cheat.git
synced 2025-12-13 18:52:06 +01:00
Compare commits
9 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
b6137cac8b | ||
|
|
711fd02195 | ||
|
|
248f5a0526 | ||
|
|
8e7ce511bd | ||
|
|
ba7ebc8392 | ||
|
|
6670785a2a | ||
|
|
aabaab1185 | ||
|
|
22eb1f2df4 | ||
|
|
a519ea163e |
@@ -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.18')
|
options = docopt(__doc__, version='cheat 2.1.19')
|
||||||
|
|
||||||
# list directories
|
# list directories
|
||||||
if options['--directories']:
|
if options['--directories']:
|
||||||
|
|||||||
23
cheat/cheatsheets/apt
Normal file
23
cheat/cheatsheets/apt
Normal file
@@ -0,0 +1,23 @@
|
|||||||
|
# To search a package:
|
||||||
|
apt search package
|
||||||
|
|
||||||
|
# To show package informations:
|
||||||
|
apt show package
|
||||||
|
|
||||||
|
# To fetch package list:
|
||||||
|
apt update
|
||||||
|
|
||||||
|
# To download and install updates without installing new package:
|
||||||
|
apt upgrade
|
||||||
|
|
||||||
|
# To download and install the updates AND install new necessary packages:
|
||||||
|
apt dist-upgrade
|
||||||
|
|
||||||
|
# Full command:
|
||||||
|
apt update && apt dist-upgrade
|
||||||
|
|
||||||
|
# To install a new package(s):
|
||||||
|
apt install package(s)
|
||||||
|
|
||||||
|
# To uninstall package(s)
|
||||||
|
apt remove package(s)
|
||||||
@@ -19,6 +19,9 @@ docker inspect --format {{.State.Pid}} <container_name_or_ID>
|
|||||||
# http://nathanleclaire.com/blog/2014/07/12/10-docker-tips-and-tricks-that-will-make-you-sing-a-whale-song-of-joy/
|
# http://nathanleclaire.com/blog/2014/07/12/10-docker-tips-and-tricks-that-will-make-you-sing-a-whale-song-of-joy/
|
||||||
docker inspect --format='{{json .Volumes}}' <container_id> | python -mjson.tool
|
docker inspect --format='{{json .Volumes}}' <container_id> | python -mjson.tool
|
||||||
|
|
||||||
|
# Copy files/folders between a container and your host
|
||||||
|
docker cp foo.txt mycontainer:/foo.txt
|
||||||
|
|
||||||
# list currently running containers
|
# list currently running containers
|
||||||
docker ps
|
docker ps
|
||||||
|
|
||||||
|
|||||||
@@ -3,3 +3,6 @@ ping -c 15 www.example.com
|
|||||||
|
|
||||||
# ping a host with a total count of 15 packets overall, one every .5 seconds (faster ping).
|
# ping a host with a total count of 15 packets overall, one every .5 seconds (faster ping).
|
||||||
ping -c 15 -i .5 www.example.com
|
ping -c 15 -i .5 www.example.com
|
||||||
|
|
||||||
|
# test if a packet size of 1500 bytes is supported (to check the MTU for example)
|
||||||
|
ping -s 1500 -c 10 -M do www.example.com
|
||||||
|
|||||||
2
setup.py
2
setup.py
@@ -3,7 +3,7 @@ import os
|
|||||||
|
|
||||||
setup(
|
setup(
|
||||||
name = 'cheat',
|
name = 'cheat',
|
||||||
version = '2.1.18',
|
version = '2.1.19',
|
||||||
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