Skip to content

Instantly share code, notes, and snippets.

@jonigl
jonigl / Convert .mov or .MP4 to .gif.md
Created February 26, 2025 19:18 — forked from SheldonWangRJT/Convert .mov or .MP4 to .gif.md
Convert Movie(.mov) file to Gif(.gif) file in one command line in Mac Terminal

This notes is written by Sheldon. You can find me with #iOSBySheldon in Github, Youtube, Facebook, etc.

Need

Convert .mov/.MP4 to .gif

Reason

As a developer, I feel better to upload a short video when I create the pull request to show other viewers what I did in this PR. I tried .mov format directly got after finishing recording screen using Quicktime, however, gif offers preview in most web pages, and has smaller file size.

This is not limited to developer, anyone has this need can use this method to convert the files.

@jonigl
jonigl / Slack app README.md
Last active May 17, 2022 15:17 — forked from seratch/README.md
Sign in with Slack - the simplest example

You can run this app by following the steps below:

Set up your Slack app

  • Create a new Slack app from https://api.slack.com/apps?new_app=1
  • Go to OAuth & Permissions
    • Add identity.basic & identity.email to User Token Scopes
    • Add OAuth Redirect URL
  • Go to Basic Information
  • Grab the Client ID & Client Secret in the page
@jonigl
jonigl / add-team-to-repos.js
Last active December 1, 2021 16:45 — forked from cohandv/add-team-to-repos.js
Add a new team to all Github repos in an organization
/*
* Adds a team to all the repos in a Github organization. This is a tedious
* process in the UI. You'll need a newer version of node to run this (e.g 9+)
* because it uses async/await.
*
* Instructions:
*
* 1. Copy this file somewhere on your computer, e.g. ~/addteamrepos.js
* 2. Fill in the uppercase variables below with the right values
* 3. Run this file: `$ node ~/addteamrepos.js`
Add the following in .zshrc:
...
plugins=(osx git zsh-autosuggestions zsh-syntax-highlighting zsh-nvm docker kubectl)
...
### Fix slowness of pastes with zsh-syntax-highlighting.zsh
pasteinit() {
OLD_SELF_INSERT=${${(s.:.)widgets[self-insert]}[2,3]}
zle -N self-insert url-quote-magic # I wonder if you'd need `.url-quote-magic`?
function FindProxyForURL(url, host) {
PROXY = "PROXY proxy.corp.ipsy.com:80; DIRECT";
hosts = ["*.acloud.guru", "ifconfig.me"];
for (let i = 0; i < hosts.length; i++) {
if (shExpMatch(host, hosts[i])) {
return PROXY;
}
}
return "DIRECT";
}
@jonigl
jonigl / github.bash
Created May 15, 2020 16:51 — forked from igrigorik/github.bash
Open GitHub URL for current directory/repo...
alias gh="open \`git remote -v | grep git@github.com | grep fetch | head -1 | cut -f2 | cut -d' ' -f1 | sed -e's/:/\//' -e 's/git@/http:\/\//'\`"
@jonigl
jonigl / cloudSettings
Last active April 27, 2020 14:09
test
{"lastUpload":"2020-04-27T14:09:27.441Z","extensionVersion":"v3.4.3"}
@jonigl
jonigl / ec2volList.py
Created March 10, 2020 01:22 — forked from chemar/ec2volList.py
AWS EC2 list volumes and attributes using boto3
import boto3
ec2 = boto3.resource('ec2')
volume_iterator = ec2.volumes.all()
for v in volume_iterator:
for a in v.attachments:
print "{0} {1} {2}".format(v.id, v.state, a['InstanceId'])
# Require Node.js core modules.
fs = require 'fs'
url = require 'url'
http = require 'http'
querystring = require 'querystring'
#### The Pixel Ping server
# Keep the version number in sync with `package.json`.
VERSION = '0.1.3'
@jonigl
jonigl / bash
Last active September 1, 2018 22:45 — forked from jonashackt/bash
Remote debugging Spring Boot
### java -jar
address = ip:port
address = *:port (* wildcard allow any ip address)
java -Xdebug -Xrunjdwp:transport=dt_socket,server=y,address=*:5005,suspend=y -jar target/cxf-boot-simple-0.0.1-SNAPSHOT.jar
### Maven
Debug Spring Boot app with Maven: