This list served quite some people but someone else did a better job since.
Go to https://github.com/umpirsky/country-list for a list in your language and format.
I've also compiled a list of nationalities
This list served quite some people but someone else did a better job since.
Go to https://github.com/umpirsky/country-list for a list in your language and format.
I've also compiled a list of nationalities
#!/bin/sh | |
# This script will install Command Line Tools for Xcode on a fresh installation of OS X. | |
# Usage: curl https://raw.github.com/gist/3053979/install-command-line-tools-for-xcode.sh | sh | |
DMG='command_line_tools_for_xcode_june_2012.dmg' | |
cd $HOME/Downloads | |
if [ ! -f ./$DMG ]; then | |
echo 'Command Line Tools for Xcode not downloaded.' |
tell application "Mail" | |
set theSubject to "Subject" -- the subject | |
set theContent to "Content" -- the content | |
set theAddress to "xxx@163.com" -- the receiver | |
set theSignatureName to "signature_name"-- the signature name | |
set theAttachmentFile to "Macintosh HD:Users:moligaloo:Downloads:attachment.pdf" -- the attachment path | |
set msg to make new outgoing message with properties {subject: theSubject, content: theContent, visible:true} |
osascript send-imessage.scpt "hello" "Homam Hosseini" | |
osascript send-imessage-pic.scpt `realpath northamerica-neb.jpg` "Homam Hosseini" |
echo "Creating an SSH key for you..." | |
ssh-keygen -t rsa | |
echo "Please add this public key to Github \n" | |
echo "https://github.com/account/ssh \n" | |
read -p "Press [Enter] key after this..." | |
echo "Installing xcode-stuff" | |
xcode-select --install |
// Must install ImageMagick first | |
http://www.imagemagick.org/script/index.php | |
//This compresses a jpg with no visible loss of quality. Add in your own file names for target.jpg and result.jpg | |
convert -strip -interlace Plane -sampling-factor 4:2:0 -quality 85% target.jpg result.jpg | |
// This does the same as above but to an entire folder (will overwrite original files): | |
mogrify -strip -interlace Plane -sampling-factor 4:2:0 -quality 85% *.jpg | |
//This does the same thing but to all subfolders as well (Be careful with this one it will overwrite all original files) |
validate_sheet() | |
set coins to {} | |
-- retrieve the list of coins from number | |
tell application "Numbers" | |
tell table 1 of sheet 1 of document 1 | |
set cntRow to count row | |
set cntCol to count column | |
#!/usr/local/bin/python | |
# based on the script by MR Jain at https://gist.github.com/mrjain/891cc88809697fb6a9c8872942fa8873#file-hello_world-py | |
import sys, getopt | |
# Add the pandas library | |
import pandas as pd | |
import pandas_datareader.data as web | |
import psycopg2 as pg | |
import pandas.io.sql as psql |
After automatically updating Postgres to 10.0 via Homebrew, the pg_ctl start command didn't work. | |
The error was "The data directory was initialized by PostgreSQL version 9.6, which is not compatible with this version 10.0." | |
Database files have to be updated before starting the server, here are the steps that had to be followed: | |
# need to have both 9.6.x and latest 10.0 installed, and keep 10.0 as default | |
brew unlink postgresql | |
brew install postgresql@9.6 | |
brew unlink postgresql@9.6 | |
brew link postgresql |
;;; package --- Fix permissions for Emacs.app on macOS Catalina | |
;;; Author: Artem Loenko | |
;;; Mail-To: <artyom.loenko@mac.com> | |
;;; Commentary: | |
;;; Code: | |
(defconst _default-emacs-app-plist-path "/Applications/Emacs.app/Contents/Info.plist") | |
(defconst _temp-buffer-name "*fixing Emacs permissions*") | |
(defconst _temp-buffer (get-buffer-create _temp-buffer-name)) | |
(with-current-buffer _temp-buffer (erase-buffer)) |