Note
Highlights information that users should take into account, even when skimming.
Tip
Optional information to help a user be more successful.
Important
Crucial information necessary for users to succeed.
[!WARNING]
Note
Highlights information that users should take into account, even when skimming.
Tip
Optional information to help a user be more successful.
Important
Crucial information necessary for users to succeed.
[!WARNING]
const { execSync } = require('child_process') | |
const { createHash } = require('crypto') | |
const invertColor = require('invert-color') | |
const branchName = execSync('git rev-parse --abbrev-ref HEAD') | |
const hash = createHash('sha256') | |
hash.update(branchName) | |
const color = '#' + hash.digest().toString('hex').substring(0, 6) | |
const invertedColor = invertColor(color, true) |
<?php | |
/** | |
* //JT 13.12.19: create_function() is deprecated. | |
*/ | |
include 'tabs.php'; | |
class Tabify_Edit_Screen_Edit_Screen { |
REMOTE=origin | |
BRANCH=$(git rev-parse --abbrev-ref HEAD) | |
BATCH_SIZE=10 | |
# check if the branch exists on the remote | |
# if git show-ref --quiet --verify refs/remotes/$REMOTE/$BRANCH; then | |
# # if so, only push the commits that are not on the remote already | |
# range=$REMOTE/$BRANCH..HEAD | |
# else | |
# # else push all the commits |
function squarify (children, row, width) { | |
if (children.length === 1) { | |
layoutLastRow(row, children, width) | |
return | |
} | |
const rowWithChild = [...row, children[0]] | |
if (row.length === 0 || worst(row, width) >= worst(rowWithChild, width)) { |
procedure squarify(list of real children, list of real row,real w) | |
begin | |
real c = head(children); | |
if worst(row, w) ≤ worst(row++[c], w) then | |
squarify(tail(children), row++[c], w) | |
else | |
layoutrow(row); | |
squarify(children, [], width()); | |
fi | |
end |
#!/bin/sh | |
git filter-branch --env-filter ' | |
OLD_EMAIL="[email protected]" | |
CORRECT_NAME="Ayo" | |
CORRECT_EMAIL="[email protected]" | |
if [ "$GIT_COMMITTER_EMAIL" = "$OLD_EMAIL" ] | |
then | |
export GIT_COMMITTER_NAME="$CORRECT_NAME" | |
export GIT_COMMITTER_EMAIL="$CORRECT_EMAIL" |
-- run first thing in the morning, e.g., from cron | |
tell application "Things3" | |
set theToken to "your-auth-token" | |
set theTodos to to dos of list "Today" | |
repeat with aTodo in theTodos | |
set tagList to tags of aTodo | |
repeat with aTag in tagList | |
if (name of aTag as text) is "Evening" |
version: '3' | |
services: | |
app: | |
image: nginx:alpine | |
ports: ["80:80"] | |
restart: unless-stopped | |
restarter: | |
image: docker:cli | |
volumes: ["/var/run/docker.sock:/var/run/docker.sock"] |
See this issue.
Docker best practise to Control and configure Docker with systemd.
Create daemon.json
file in /etc/docker
:
{"hosts": ["tcp://0.0.0.0:2375", "unix:///var/run/docker.sock"]}