Skip to content

Instantly share code, notes, and snippets.

<!doctype html>
<html lang="en">
<head>
<meta charset="utf-8">
<title>Bet game</title>
<meta name="description" content="Bet gamed">
<meta name="author" content="Anderson">
</head>
@Andsbf
Andsbf / 01_hello_world.js
Last active August 29, 2015 14:19
Learnyounode - I
console.log("HELLO WORLD")
@Andsbf
Andsbf / git_ignore_ds_store.md
Last active December 3, 2015 22:15
Make Git always ignore .DS_store file

Make Git never ask you again about .DS_Store

In the terminal:

echo .DS_Store > ~/.gitignore_global

Now tell git to use it for all repositories:

git config --global core.excludesfile ~/.gitignore_global

[[ -s "$HOME/.profile" ]] && source "$HOME/.profile" # Load the default .profile
[[ -s "$HOME/.rvm/scripts/rvm" ]] && source "$HOME/.rvm/scripts/rvm" # Load RVM into a shell session *as a function*
export NVM_DIR="$HOME/.nvm"
. "$(brew --prefix nvm)/nvm.sh"
# Git-bash-prompt
if [ -f "$(brew --prefix bash-git-prompt)/share/gitprompt.sh" ]; then
#!/bin/bash
n=0; ls -tr | while read i; do n=$((n+1)); mv -- "$i" "$(printf '%03d' "$n").JPG"; done
[Unit]
Description=Download IP Geolocation Database from Maxmind.com
[Service]
Type=oneshot
WorkingDirectory=/tmp
ExecStart=/bin/sh -c "\
mkdir -p /home/core/ip_database \
curl -O http://geolite.maxmind.com/download/geoip/database/GeoLite2-City.mmdb.gz ; \
gunzip GeoLite2-City.mmdb.gz ; \
curl -O http://geolite.maxmind.com/download/geoip/database/GeoLite2-City.md5 ; \