This file contains 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 sleep(ms) { | |
return new Promise((resolve) => setTimeout(resolve, ms)); | |
} | |
const sleepyLoop = async() => { | |
for (const [index, url] of urls.entries()) { | |
spam(url, index) | |
await sleep(100) | |
} | |
} |
This file contains 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
CREATE TABLE pending_transactions | |
(id TEXT PRIMARY KEY, | |
acct INTEGER, | |
amount INTEGER, | |
description TEXT, | |
date TEXT, | |
FOREIGN KEY(acct) REFERENCES accounts(id)); | |
CREATE TABLE created_budgets (month TEXT PRIMARY KEY); | |
CREATE TABLE spreadsheet_cells | |
(name TEXT PRIMARY KEY, |
This file contains 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
# encrypt file.txt to file.enc using 256-bit AES in CBC mode | |
openssl enc -aes-256-cbc -salt -in file.txt -out file.enc | |
# the same, only the output is base64 encoded for, e.g., e-mail | |
openssl enc -aes-256-cbc -a -salt -in file.txt -out file.enc | |
# To decrypt file.enc you or the file’s recipient will need to remember the cipher and the passphrase. | |
# decrypt binary file.enc | |
openssl enc -d -aes-256-cbc -in file.enc |
This file contains 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
Cypress.Commands.add('getInputByName', name => { | |
return cy.get(`[name="${name}"]`); | |
}); | |
Cypress.Commands.add('getByTestTag', tag => { | |
return cy.get(`[data-test-id="${tag}"]`); | |
}); | |
Cypress.Commands.add('clickRecaptcha', () => { | |
cy.window().then(win => { |
This file contains 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
const fs = require('fs') | |
const DIST_SCRIPTS = { | |
'start': 'npm run start-main-script' | |
} | |
fs.readFile('package.json', 'utf8', (err, data) => { | |
const distPackage = JSON.parse(data) | |
distPackage['scripts'] = DIST_SCRIPTS | |
delete distPackage['devDependencies'] |
This file contains 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
#!/bin/bash | |
# For instance with feature/add_new_feature_HEYT-653 | |
# $ git commit -m"Fixed bug" | |
# will result with commit "[HEYT-653] Fixed bug" | |
# Customize which branches should be skipped when prepending commit message. | |
if [ -z "$BRANCHES_TO_SKIP" ]; then | |
BRANCHES_TO_SKIP=(master develop test) |