Substack https://aljamal.substack.com/p/homoiconic-python
atom=lambda x:not isinstance(x,list)
eq=lambda x,y:x == y
car=lambda x:x[0]
cdr=lambda x:x[1:]
Substack https://aljamal.substack.com/p/homoiconic-python
atom=lambda x:not isinstance(x,list)
eq=lambda x,y:x == y
car=lambda x:x[0]
cdr=lambda x:x[1:]
package main | |
import ( | |
"fmt" | |
"os" | |
"strconv" | |
"time" | |
linuxproc "github.com/c9s/goprocinfo/linux" | |
) |
# push mode will look about like this: | |
if __name__ == '__main__': | |
inventory = TomlInventory("inventory/inventory.toml") | |
inventory.ssh([WebServerRole(), AnotherRole() ]) | |
# if you want to run check mode, you can still access it, though it is not the default: | |
inventory.ssh([WebServers(), AnotherRole() ], check=True) |
#!/usr/bin/env bash | |
# HubCrypt | |
# ======== | |
# | |
# Decrypt a file encrypted using hubencrypt (ok, it's just openssl + rsautl + | |
# your SSH keys). It needs the private key that matches your last public key | |
# listed at github.com/<user>.keys | |
# |
This is way more complicated than it should be. The following conditions need to be met :
In this particular case, I'm interested in bringing in the 'default' template of jsdoc as a sub-directory in my project so I could potentially make changes to the markup it genereates while also being able to update from upstream if there are changes. Ideally their template should be a separate repo added to jsdoc via a submodule -- this way I could fork it and things would be much easier.... but, it is what it is.
After much struggling with git, subtree and git-subtree, I ended up finding this http://archive.h2ik.co/2011/03/having-fun-with-git-subtree/ -- it basically sets up separate branches from tracking remote, the particular sub-directory, and uses git subtree contrib module to pull it all togther. Following are