Skip to content

Instantly share code, notes, and snippets.

View skobba's full-sized avatar

Gjermund Skobba skobba

View GitHub Profile
chmod u=rx file (Give the owner rx permissions, not w)
chmod go-rwx file (Deny rwx permission for group, others)
chmod g+w file (Give write permission to the group)
chmod a+x file1 file2 (Give execute permission to everybody)
chmod g+rx,o+x file (OK to combine like this with a comma)
@skobba
skobba / Jenkins.txt
Last active July 9, 2019 11:10
Jenkins
# Force Build
Jenkins->FDK->build_all, Build With Parameters, after=ønsket git-commit, ref=refs/heads/develop (eller annen branch)
# cJenkins (terminal)
python cjenkins -u <username> -p <password> -l <jenkins 1 address> .. <jenkins n address>
@skobba
skobba / curl.sh
Last active February 18, 2021 00:36
curl
# POST w/ token
curl -H "Authorization: bearer $TOKEN" -H "Content-Type: application/json" -X POST -d '
{ "invoice":
{
"matter": "5bc9a264da9a42bee9c9cf48",
"unitPrice": 10200
}
}' http://localhost:4000/api/invoices
# POST
file-icons
# Recompose
A recompose stack is something like this:
import * as R from "recompose";
const enhance = R.compose(
R.withProps({text: "Click Me"}),
R.withStateHandler({ active: false }, {
onClick: ({ active }) => event => ({
active: !active,
}),
tree -I "node_modules|bower_components" -L 3
@skobba
skobba / deploying-kubernetes-on-smartos.md
Last active February 17, 2021 04:59
Deploying Kubernetes on SmartIOS
# git reset (n: number of commits)
git reset HEAD~n
# Rename branch
git branch -m <oldname> <newname>
git push -f
No upstream branch...
git push origin HEAD
@skobba
skobba / lsblk.md
Created July 19, 2019 08:14
lsblk

List partitions w/ disk id and serial

lsblk -o name,model,serial