'use strict';
const moment = require('moment');
class DateOnly {
/**
* @param {moment|Date|string} input an object or a string moment.js can parse
*/
constructor(input) {
Easy to check which branches will be deleted by removing at the bottom of | sh
:)
git branch -r --merged master | sed -e 's#origin/#:#g' | egrep -v 'master|release|ADD BRANCH NAMES YOU WANT TO LEAVE' | sed 's/^/git push origin'/g | sh
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
'use strict'; | |
const qs = require('qs'); | |
function format_url(base) { | |
const remove_trailing_slash = (element) => { | |
return element.endsWith('/') ? element.slice(1, -1) : element; | |
}; | |
const remove_leading_slash = (element) => { |
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
module.exports = { | |
parserOptions: { | |
ecmaVersion: 2020, | |
}, | |
env: { | |
es6: true, | |
}, | |
root: true, | |
extends: 'eslint:recommended', | |
rules: { |
This instruction will store the source in /usr/local/src
following the linux convention.
$ sudo apt update
$ sudo apt install libssl-dev autoconf automake libtool python-setuptools python-dev
$ cd /usr/local/src
$ sudo git clone https://github.com/facebook/watchman.git
$ cd watchman
$ sudo git checkout v4.9.0 # the latest stable release
$ sudo ./autogen.sh
Following the official guide, you'll bump into the following error:
$ sudo zypper ref
Repository 'Google-Chrome' is up to date.
Retrieving repository 'Yarn' metadata --------------------------------------------------------------------------------------------------------------------------------------------------------------------------[\]
Warning: File 'repomd.xml' from repository 'Yarn' is signed with an unknown key '9CBBB5586963F07F'.
Note: Signing data enables the recipient to verify that no modifications occurred after the data
were signed. Accepting data with no, wrong or unknown signature can lead to a corrupted system
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
module ActiveJobRetryControlable | |
extend ActiveSupport::Concern | |
DEFAULT_RETRY_LIMIT = 5 | |
attr_reader :attempt_number | |
module ClassMethods | |
def retry_limit(retry_limit) | |
@retry_limit = retry_limit |
- You have GitHub CLI installed and logged in
- You have gh repo-collab extention intalled
- You have the permission to list all repositories in your organisation
# 50 is the number of repositories to be listed
gh repo list -L 50 <organisation> | \
awk '{print $1}' | \