Skip to content

Instantly share code, notes, and snippets.

# 1. Download the top 100 from CoinMarketCap.
# 2. Download all USDT-based pairs from Binance.
# 3. Print out a list of the top 100 coins tradeable on Binance.
#
# The theory is that the top coins are going to perform best
# in a bull market. With this information we can build a momentum
# strategy based on the top coins only.
# Suggestion usually is to check the top 100 coins monthly,
# then rebalance the portfolio.
@Zettt
Zettt / readme.md
Last active March 11, 2023 10:11
Paste by Typing: Binance Copy/Paste (Mac only)

If you are annoyed as much as I am by Binance inability to paste clipboard values into the order boxes, you're welcome. (Please do us all a favor and file a bug report too!)

On a Mac you can simply use an AppleScript to type everything that is on the clipboard for you. The script is this:

try
	the clipboard as text
on error
	set the clipboard to " "
end try

Keybase proof

I hereby claim:

  • I am zettt on github.
  • I am zettt (https://keybase.io/zettt) on keybase.
  • I have a public key ASAEMOLtmYzMeH7C9fffIxFRfc8f9xURmBnh9c5hkgz7pQo

To claim this, I am signing this object:

@Zettt
Zettt / packagizer.sh
Last active December 13, 2023 02:47
TextBundle Packagizer -- This is a script that helps to create bundled folders of Markdown files. It downloads online-linked images to an assets directory, as well as copies local files to it. It's not finished yet.
#!/bin/sh
function usage {
echo "This script creates a folder containing all linked ![images]()"
echo "of a Markdown file -- even linked ones from the Internet."
echo ""
echo "It takes one argument: the file it should process."
echo
echo "When a file argument is present, it creates a new folder for:"
echo "a) the Markdown file"
@Zettt
Zettt / rule of thirds.markdown
Last active May 15, 2016 14:28
This is a Calca document to calculate positions for rulers of a presentation, a video, graphical document, etc. As a video editor I can tell that "TV-safe areas" are a good rule of thumb for presentations, because there's always someone sitting in the back, the projector is never centered, and so forth.

Credits

Andreas Zeitler
zCasting 3000
zcasting3000.com

Setup

aspect ratio = 16 / 9 =>

width = 1920

@Zettt
Zettt / gifenc.sh
Last active January 29, 2016 14:49 — forked from goncalossilva/gifenc.sh
Handy script to encode gif using ffmpeg (2.6 or above). Put somewhere in your `$PATH` and I hope it works for you.
#!/bin/sh
# sh gifenc.sh -i input.mp4 -o output.gif
# defaults
palette="/tmp/palette.png" #location of temporary palette file
fps=20
filters=
#usage and parameter assembly
@Zettt
Zettt / weekprojects.applescript
Last active September 23, 2018 11:48
Week Projects: This is a week-based version of my previous Day Projects script (https://gist.github.com/Zettt/1401813)
-- Week Projects
--
-- Created by Zettt on 2015-12-28
-- zCasting 3000.
--
-- This script creates "Week Projects" in OmniFocus.
--
-- I use these "Week Projects" to put stuff, that I need to
-- do during a specific week, but aren't big enough to be their own project.
-- Things like "Call the doctor on Wednesday" or
@Zettt
Zettt / keynote.md
Created July 2, 2015 20:56
Things I learned about Keynote today

Things I learned about Keynote today

  • Keynote has Boolean operators
  • Curves defaults can be set in prefs (Bézier vs. Spline)
  • Rather than trying to master the Bézier tool, in order to mask something, make many small straight lines.
  • Magic Move can animate lots of things. Including color, reflection, shape, rotation, and many more parameters.
@Zettt
Zettt / screencast typing.scpt
Created May 28, 2015 13:48
This script types a long string without errors(!!!) for you. Delay between keystrokes is variable. Originally taken from http://christianheilmann.com/2014/01/09/autmating-typing-in-screencasts-with-applescript-or-how-to-look-like-a-hollywood-hacker/
set myLines to "Brainstorming is a group or individual creativity technique by which efforts are made to find a conclusion for a specific problem by gathering a list of ideas spontaneously contributed by its member(s). The term was popularized by Alex Faickney Osborn in the 1953 book Applied Imagination. Osborn claimed that brainstorming was more effective than individuals working alone in generating ideas, although more recent research has questioned this conclusion. Today, the term is used as a catch all for all group ideation sessions."
set recordedApp to "iOS Simulator"
set typingDelay to "0.1" --try 0.05 so something much faster (double, actually)
--make sure the recorded app is foreground
--otherwise it can result into missing strings
activate application recordedApp
delay 3
repeat with currentline in myLines
@Zettt
Zettt / spotifyplayback.scpt
Created May 23, 2015 08:07
Playhead forward/backward - Because Spotify has stupidly removed the possibility to skip forward and backward using keyboard shortcuts, we now have to resort to do this via AppleScript. Well, it could be harder. The script below jumps 3 seconds ahead. Bind to keyboard shortcuts such as →. You may use ⇧→ to skip 10 seconds. This is how it was in …
tell application "Spotify"
if player state is playing then
set playPos to player position + 3.0
set player position to playPos
end if
end tell