Skip to content

Instantly share code, notes, and snippets.

View drklrd's full-sized avatar
🏔️
I want to see mountains again, Gandalf, mountains!

Saurav Bhattarai drklrd

🏔️
I want to see mountains again, Gandalf, mountains!
View GitHub Profile
@geek-at
geek-at / trash.sh
Created August 13, 2020 07:27
The script used to trash a banking phishing site
#!/bin/bash
while :; do
verf=$(cat /dev/urandom | tr -dc '0-9' | fold -w 8 | head -n 1)
pin=$(cat /dev/urandom | tr -dc '0-9' | fold -w 5 | head -n 1)
ip=$(printf "%d.%d.%d.%d\n" "$((RANDOM % 256))" "$((RANDOM % 256))" "$((RANDOM % 256))" "$((RANDOM % 256))")
@nicolasdao
nicolasdao / webpack.md
Last active June 22, 2024 02:56
Basic damn Webpack config for simple transpilation ES6 to ES5

Install

npm install -D acorn babel-loader @babel/core @babel/preset-env babel-polyfill webpack webpack-cli uglifyjs-webpack-plugin --save-dev

webpack-cli and acorn are dependencies that you, unfortunately, have to install if you want to run this god damn thing without any obscure warnings or errors.

Build

Configure Webpack

@stepankuzmin
stepankuzmin / README.md
Created January 4, 2019 10:22
Gitlab AutoDevops on DigitalOcean k8s
@qoomon
qoomon / conventional-commits-cheatsheet.md
Last active November 19, 2025 01:46
Conventional Commits Cheatsheet
# Install Mapshaper
npm install -g mapshaper
# Install Tippecanoe
brew install tippecanoe
# Make a directory for your geojson files and convert all the shapefiles in a directory to geojson
mkdir ../geojson
for f in *.shp;
do
@maxivak
maxivak / readme.md
Last active April 22, 2025 03:02
Restore repo from Gitlab bundle file

Gitlab exports repositories to tar archive which contains .bundle files.

We have repo.bundle file and we want to restore files from it.

  • create bare repo from bundle file
git clone --mirror myrepo.bundle my.git
@joshbuchea
joshbuchea / semantic-commit-messages.md
Last active November 18, 2025 22:53
Semantic Commit Messages

Semantic Commit Messages

See how a minor change to your commit message style can make you a better programmer.

Format: <type>(<scope>): <subject>

<scope> is optional

Example

@geog4046instructor
geog4046instructor / leaflet-geojson-custom-icon.js
Last active May 6, 2025 13:32
Leaflet - Create a custom icon to use with a GeoJSON layer instead of the default blue marker
/*
* Create a custom icon to use with a GeoJSON layer instead of the default blue
* marker. This snippet assumes the map object (map) and GeoJSON object
* (myLayerData) have already been declared.
*/
// replace Leaflet's default blue marker with a custom icon
function createCustomIcon (feature, latlng) {
let myIcon = L.icon({
iconUrl: 'my-icon.png',
@oguya
oguya / installing_onadata.md
Last active February 3, 2019 16:00
step-by-step notes for install Classic Ona(OnaData) on an Ubuntu 16.04 host

Installing OnaData(Classic ONA) on Ubuntu 16.04

The following are step-by-step instructions for installing Classic ONA(OnaData) on an Ubuntu 16.04 machine.

  • clone ona repo

      $ cd /opt
      $ git clone https://github.com/onaio/onadata.git
      $ mv onadata onadata-venv
    

$ cd onadata-venv

@montrealist
montrealist / deploy-to-digital-ocean.markdown
Last active January 7, 2024 11:57
How to deploy files to Digital Ocean when pushing to Gitlab

How to get auto-deploy working from Gitlab to your Digital Ocean (DO) server.

Install https://github.com/olipo186/Git-Auto-Deploy (via apt-get):

sudo apt-get install software-properties-common
sudo add-apt-repository ppa:olipo186/git-auto-deploy
sudo apt-get update
sudo apt-get install git-auto-deploy