wget -qO - https://www.mongodb.org/static/pgp/server-5.0.asc | sudo apt-key add -
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains hidden or 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
#!/usr/bin/env python | |
import dbus | |
import dbus.service | |
class FakeScreenSaver(dbus.service.Object): | |
def __init__(self): | |
self.session_bus = dbus.SessionBus() | |
name = dbus.service.BusName('org.freedesktop.ScreenSaver', bus=self.session_bus) | |
dbus.service.Object.__init__(self, name, '/org/freedesktop/ScreenSaver') |
Once in a while, you may need to cleanup resources (containers, volumes, images, networks) ...
// see: https://github.com/chadoe/docker-cleanup-volumes
$ docker volume rm $(docker volume ls -qf dangling=true)
$ docker volume ls -qf dangling=true | xargs -r docker volume rm
helpful sources:
-
Track file from external directory:
git --git-dir=path/to/repository --work-tree=path/to/external/directory/to/track add foobar_file
-
git init --separate-git-dir /path/to/ext
Squashing last 3 commits to 1 commit: git rebase -i HEAD~3
source
This file contains hidden or 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
function transfer | |
if test (count $argv) -eq 0 | |
echo "No arguments specified. Usage:\necho transfer /tmp/test.md\ncat /tmp/test.md | transfer test.md" | |
return 1 | |
end | |
## get temporarily filename, output is written to this file show progress can be showed | |
set tmpfile ( mktemp -t transferXXX ) | |
## upload stdin or file |
YARD CHEATSHEET http://yardoc.org
May 2020 - updated fork: https://gist.github.com/phansch/db18a595d2f5f1ef16646af72fe1fb0e
cribbed from http://pastebin.com/xgzeAmBn
Templates to remind you of the options and formatting for the different types of objects you might want to document using YARD.