This file contains hidden or 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/sh | |
# Called by "git push" after it has checked the remote status, | |
# but before anything has been pushed. | |
# | |
# If this script exits with a non-zero status nothing will be pushed. | |
# | |
# Steps to install, from the root directory of your repo... | |
# 1. Copy the file into your repo at `.git/hooks/pre-push` | |
# 2. Set executable permissions, run `chmod +x .git/hooks/pre-push` |
This file contains hidden or 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
/* | |
The original script: https://github.com/dherbst/slack-invite-script/blob/master/code.js | |
*/ | |
/* | |
Get channels from: curl 'https://golang.slack.com/api/channels.list?token={token}' | json_pp | |
*/ | |
function getInviteChannels() { | |
return ['C123123123']; |
This file contains hidden or 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 | |
# Generate a Markdown change log of pull requests from commits between two tags | |
# Author: Russell Heimlich | |
# URL: https://gist.github.com/kingkool68/09a201a35c83e43af08fcbacee5c315a | |
# HOW TO USE | |
# Copy this script to a directory under Git version control | |
# Make the script executable i.e. chmod +x changelog.sh | |
# Run it! ./changelog.sh | |
# Check CHANGELOG.md to see your results |
This file contains hidden or 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
# API Key 可以在以下頁面建立: | |
# https://max.maicoin.com/api_tokens/new | |
# | |
MAX_API_KEY= | |
MAX_API_SECRET= |
This file contains hidden or 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
func (s Harmonic) SharkLong(highs, lows *types.Queue, p float64) float64 { | |
score := 0. | |
for x := 5; x < 300; x++ { | |
X := lows.Index(x) | |
for a := 4; a < x; a++ { | |
if highs.Index(a-1) < highs.Index(a) && highs.Index(a) > highs.Index(a+1) { | |
A := highs.Index(a) | |
XA := math.Abs(X - A) | |
hB := A - 0.382*XA | |
lB := A - 0.618*XA |
This file contains hidden or 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
func (s Harmonic) SharkLong(highs, lows *types.Queue, p float64) float64 { | |
score := 0. | |
for x := 5; x < 300; x++ { | |
X := lows.Index(x) | |
for a := 4; a < x; a++ { | |
if highs.Index(a-1) < highs.Index(a) && highs.Index(a) > highs.Index(a+1) { | |
A := highs.Index(a) | |
XA := math.Abs(X - A) | |
hB := A - 0.382*XA | |
lB := A - 0.618*XA |
OlderNewer