Skip to content

Instantly share code, notes, and snippets.

@fuse
fuse / Gemfile
Created October 29, 2013 16:25 — forked from nicoolas25/Gemfile
gem 'devise'
gem 'omniauth'
gem 'omniauth-facebook'
gem 'omniauth-google-oauth2'
gem 'omniauth-windowslive'
@fuse
fuse / _docker-machine
Created January 28, 2016 10:04
Extend docker-machine to have a use command
#compdef docker-machine
# ------------------------------------------------------------------------------
# Description
# -----------
#
# Completion script for Docker Machine (http://docs.docker.com/machine/).
# Adapted from boot2docker completion by hhatto (https://github.com/hhatto)
# and docker completion by @aeonazaan and @bobmaerten.
#
# ------------------------------------------------------------------------------
{
"_json"=>[
{
"farm"=>{
"uid"=>"04a814ed-7041-4b04-a51b-c6bd41c593ca",
"name"=>"demo API dev",
"farm_code"=>"30247504101420"
},
"indicator"=>{
"uid"=>"970d9d0b-37d1-4602-a687-2b8ce6b621e0",
@fuse
fuse / deduplicate_1password_items.sh
Created March 26, 2023 16:13
After merging two 1password vaults I ended up with a lot of duplicates. I wanted to only keep one version of each entry.
#!/bin/bash
# This script basically find duplicateds based on titles, keep the first one and delete the other ones.
# /!\ Be careful if you have different IDs that potentially have the same title.
# You need 1password client and jq to make it work
json_data=$(op item list --format json)
duplicates=$(echo "$json_data" | jq -r '.[] | .title' | sort | uniq -d)
while read -r title; do