Skip to content

Instantly share code, notes, and snippets.

View thundernixon's full-sized avatar

Stephen Nixon thundernixon

View GitHub Profile
@fabiomaggio
fabiomaggio / git-filter-branch-move-files.md
Last active October 20, 2022 08:48
Use git filter-branch to move all projects files to a subdir and rewrite all commits
  1. Clone project

  2. Checkout all branches that contain the files that should be moved

  3. Delete the remote

  4. Run the filter-branch command:

    git filter-branch --tree-filter 'mkdir -p /path/to/tmp; mv * /path/to/tmp; mkdir subdir; mv /path/to/tmp/* subdir/' --tag-name-filter cat --prune-empty -- --all
    • All files are first copied to a temporary dir and move from there to the new destination
  • Existing tags are updated
# menuTitle : myCloud Export/Import
# shortCut : command+control+e
"""
code took from LettError known as Erik van Blokland (or Erik van Blokland known as LettError)
This is window that wraps the functionality explained here:
https://forum.robofont.com/topic/646/export-glyph-image-edit-on-ipad-reimport-as-background-image
https://gist.github.com/LettError/d0d2688abe959595a88b3fdb85c18db3
"""
from vanilla import FloatingWindow, SquareButton, TextBox
#!/bin/bash -e
pushd "$(dirname "$0")" >/dev/null
chardiffdir=$PWD
pushd "../.." >/dev/null
srcdir=$PWD
fontsample=$srcdir/misc/tools/fontsample/fontsample
popd >/dev/null
popd >/dev/null
outfile=$1
@gferreira
gferreira / bulk-list.py
Last active August 6, 2019 15:51 — forked from okay-type/bulk-list.py
dropfile-ui
# jackson # ok@yty.pe
import os
from AppKit import NSFilenamesPboardType, NSDragOperationCopy
from vanilla import Window, List, Button
class doThing():
def __init__(self, path):