Skip to content

Instantly share code, notes, and snippets.

View espoelstra's full-sized avatar

Ethan Spoelstra espoelstra

View GitHub Profile
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<array>
<dict>
<key>attributeSetting</key>
<integer>1</integer>
<key>choiceAttribute</key>
<string>selected</string>
<key>choiceIdentifier</key>
@omundy
omundy / README.md
Last active June 14, 2023 21:03
Remove Sophos from a Mac with tamper protection

Sophos Anti Virus hogging your processor? Can't remove it because of tamper protection?


# change into preferences
cd /Library/Preferences

# confirm locations of sophos files
ls com.sophos.*
@dikiaap
dikiaap / git-io-custom-url.md
Last active June 19, 2024 01:26
git.io custom URL

Update: As of 11 January 2022, git.io no longer accepts new URLs.

Command:

curl https://git.io/ -i -F "url=https://github.com/YOUR_GITHUB_URL" -F "code=YOUR_CUSTOM_NAME"

URLs that can be created is from:

  • https://github.com/*
  • https://*.github.com
@Artistan
Artistan / A Readme for Adding Certs.md
Last active March 11, 2024 21:12
Add new certificate (cert) from local/internal intranet to your mac

Add a cert to you macbook

USAGE

~/add_cert.sh my.intra.net

you will be asked for your password to add thit to keychain

  • downloads pem file
  • adds to trusted root certificates
@ntamvl
ntamvl / install-multiple-jdk-on-macos-high-sierra.md
Last active February 21, 2024 11:12
Install Multiple Java Versions on macOS High Sierra

Install Multiple Java Versions on macOS High Sierra

Install Homebrew Cask

On Mac, Homebrew is the de-facto package manager, and Homebrew Cask is the app manager. I’m going to use Cask to install Java 7 and 8.

Install Homebrew Cask first if you haven’t:

brew update
brew tap caskroom/cask
@frntn
frntn / gpg-key-validity.sh
Created June 21, 2017 01:59
GnuPG web of trust : automate multiple scenarii to help the understanding of https://www.gnupg.org/gph/en/manual/x334.html
#!/bin/bash
# Author: Matthieu Fronton <[email protected]>
# Profile: github.com/frntn
# Description: GnuPG web of trust : automate multiple scenarii to help the understanding of https://www.gnupg.org/gph/en/manual/x334.html
WAIT=4
if [ -t 1 ]; then
cya="$(tput setaf 6)"

How To - Upload and add Images to markdown files in Gist

Markdown files allow embedding images in it. However it requires the image to be hosted at some location and we can add the url of the image to embed it.

Example: ![Alternate image text](https://someurl/imagelocation/image.png)

We can use services like imgur or other services to host the images and use the hosted URL.

@stuaxo
stuaxo / fix-desktop-launcher.sh
Last active February 6, 2019 21:25
Launch desktop files instead of opening them in gedit.
$ sudo apt-get install dex
$ /usr/bin/dex -c /usr/bin/dex -t ~/.local/share/applications/
@cben
cben / dodgetocat_v2.png
Last active April 1, 2023 13:16 — forked from alienlebarge/dodgetocat_v2.png
Is there an easy way to link image in a GIST ?
dodgetocat_v2.png
@DamianMac
DamianMac / gist:a944c0fcab6db531e7a5
Created October 30, 2014 02:16
Executing a Script Task via the Octopus API
var server = "http://yourserveraddress:8065/"; //Your server and IP address
var apiKey = "API-XXXXXXXXXXXXXXXXXXXXXXXXX"; // Get this from your 'profile' page in the Octopus web portal
var endpoint = new OctopusServerEndpoint(server, apiKey);
var repository = new OctopusRepository(endpoint);
var task = new Octopus.Client.Model.TaskResource();
task.Name = "AdHocScript";
task.Description = "Script invoked via API";