Skip to content

Instantly share code, notes, and snippets.

View jose-neta's full-sized avatar

José Neta jose-neta

  • 50NOS.pt
  • Porto area, Portugal
View GitHub Profile
@jose-neta
jose-neta / get_latest_release.sh
Last active December 4, 2018 15:41 — forked from lukechilds/get_latest_release.sh
Shell - Get latest release from GitHub
#!/usr/bin/env bash
# USAGE: ./get_latest_release.sh docker/compose
account_repo=$1 # e.g.: docker/docker-compose
curl -s "https://api.github.com/repos/$account_repo/releases/latest" | jq -r .name
@jose-neta
jose-neta / snake.go
Created December 1, 2018 19:33 — forked from elwinar/snake.go
ToSnake function for golang, convention-compliant
package main
import (
"unicode"
)
// ToSnake convert the given string to snake case following the Golang format:
// acronyms are converted to lower-case and preceded by an underscore.
func ToSnake(in string) string {
runes := []rune(in)
http://www.oreilly.com/data/free/files/2014-data-science-salary-survey.pdf
http://www.oreilly.com/data/free/files/2015-data-science-salary-survey.pdf
http://www.oreilly.com/data/free/files/Data_Analytics_in_Sports.pdf
http://www.oreilly.com/data/free/files/advancing-procurement-analytics.pdf
http://www.oreilly.com/data/free/files/ai-and-medicine.pdf
http://www.oreilly.com/data/free/files/analyzing-data-in-the-internet-of-things.pdf
http://www.oreilly.com/data/free/files/analyzing-the-analyzers.pdf
http://www.oreilly.com/data/free/files/architecting-data-lakes.pdf
http://www.oreilly.com/data/free/files/being-a-data-skeptic.pdf
http://www.oreilly.com/data/free/files/big-data-analytics-emerging-architecture.pdf
bin
obj
@jose-neta
jose-neta / bullshit.js
Created November 9, 2017 02:54 — forked from raydog/bullshit.js
Bullshit as a Service
var E_PREFIX_RATE = 0.25;
// All of our word lists:
var _word_lists = {
verb : [
"implement", "utilize", "integrate", "streamline", "optimize", "evolve", "transform", "embrace",
"enable", "orchestrate", "leverage", "reinvent", "aggregate", "architect", "enhance", "incentivize",
"morph", "empower", "envisioneer", "monetize", "harness", "facilitate", "seize", "disintermediate",
@jose-neta
jose-neta / spotihosts
Created August 29, 2017 16:29
The hosts file entries to block Spotify audio ad servers.
127.0.0.1 media-match.com
127.0.0.1 adclick.g.doublecklick.net
127.0.0.1 www.googleadservices.com
127.0.0.1 open.spotify.com
127.0.0.1 pagead2.googlesyndication.com
127.0.0.1 desktop.spotify.com
127.0.0.1 googleads.g.doubleclick.net
127.0.0.1 pubads.g.doubleclick.net
127.0.0.1 audio2.spotify.com
127.0.0.1 www.omaze.com
@jose-neta
jose-neta / clean-docker-for-mac.sh
Created May 19, 2017 19:50 — forked from MrTrustor/clean-docker-for-mac.sh
This script cleans the Docker.qcow2 file that takes a lot of disk space with Docker For Mac. You can specify some Docker images that you would like to keep.
#!/bin/bash
# Copyright 2017 Théo Chamley
# Permission is hereby granted, free of charge, to any person obtaining a copy of
# this software and associated documentation files (the "Software"), to deal in the Software
# without restriction, including without limitation the rights to use, copy, modify, merge,
# publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons
# to whom the Software is furnished to do so, subject to the following conditions:
#
# The above copyright notice and this permission notice shall be included in all copies or

$project

$project will solve your problem of where to start with documentation, by providing a basic explanation of how to do it easily.

Look how easy it is to use:

import project

Get your stuff done

@jose-neta
jose-neta / pre-commit
Last active February 24, 2017 16:19
Pre-commit hook that doesn't allow you to commit a file containing tabs
#!/bin/bash
usage="File has tabs! Please remove them before commit"
staged_files=$(git diff --cached --name-only)
for sf in $staged_files; do
file_has_tabs=$(grep -r '\t' $sf)
[[ ! -z $file_has_tabs ]] && echo "$usage: $sf" && exit 88
done
@jose-neta
jose-neta / pre-commit
Created February 24, 2017 11:14 — forked from eddywashere/pre-commit
Git hook that prevents commits to master
#!/bin/sh
#
# Git hook that prevents commits to master
# use --no-verify to bypass this hook
# ex: git commit -m "init commit" --no-verify
branch=`git symbolic-ref HEAD`
if [ "$branch" = "refs/heads/master" ]; then
echo "Direct commits to the branch master are not allowed"
exit 1