Skip to content

Instantly share code, notes, and snippets.

Avatar

Edoardo Ceccarelli edoardoc

View GitHub Profile
@edoardoc
edoardoc / plpgsql_query_function_template.sql
Created December 10, 2021 16:53
PL/pgSQL Template to run inline a complicated function and get results in console
View plpgsql_query_function_template.sql
-- PL/pgSQL Template to run inline a complicated function and get results in console
DO $$
DECLARE
-- ADD QUERY DECLARATION HERE:
filteringIdOfSomeKind UUID;
-- ADD QUERY DECLARATION HERE -- END!
t timestamptz;
target record;
@stepney141
stepney141 / BookmarkAPI_en.md
Last active February 16, 2023 06:49
(DEPRECATED) Twitter Undocumented Endpoints for Bookmark
View BookmarkAPI_en.md
@ksmithut
ksmithut / .dockerignore
Last active March 2, 2023 16:32
Node Docker Compose nodemon
@tombigel
tombigel / README.md
Last active March 6, 2023 06:54 — forked from a2ikm/limit.maxfiles.plist
How to Change Open Files Limit on OS X and macOS Sierra (10.8 - 10.12)
View README.md

How to Change Open Files Limit on OS X and macOS

This text is the section about OS X Yosemite (which also works for macOS Sierra) from https://docs.basho.com/riak/kv/2.1.4/using/performance/open-files-limit/#mac-os-x

The last time i visited this link it was dead (403), so I cloned it here from the latest snapshot in Archive.org's Wayback Machine https://web.archive.org/web/20170523131633/https://docs.basho.com/riak/kv/2.1.4/using/performance/open-files-limit/

Mac OS X

To check the current limits on your Mac OS X system, run:

@ascendbruce
ascendbruce / README.md
Last active March 21, 2023 17:41
Use macOS-style shortcuts in Windows
View README.md

Use macOS-style shortcuts in Windows / keyboard mappings using a Mac keyboard on Windows

Make Windows PC's shortcut act like macOS (Mac OS X) (using AutoHotkey (ahk) script)

With this AutoHotKey script, you can use most macOS style shortcuts (eg, cmd+c, cmd+v, ...) on Windows with a standard PC keyboard.

There is a new, alternative project that does similar things and more, check it out at https://github.com/stevenilsen123/mac-keyboard-behavior-in-windows

How does it work

@tonysneed
tonysneed / Mac OS X: Open in Visual Studio Code
Last active January 19, 2023 07:21
Add a command to Finder services in Mac OSX to open a folder in VS Code
View Mac OS X: Open in Visual Studio Code
- Open Automator
- File -> New -> Service
- Change "Service Receives" to "files or folders" in "Finder"
- Add a "Run Shell Script" action
- Change "Pass input" to "as arguments"
- Paste the following in the shell script box: open -n -b "com.microsoft.VSCode" --args "$*"
- Save it as something like "Open in Visual Studio Code"
View top100AppProjects.csv
Project # of Top 100 Free Apps (US)
facebook-ios-sdk 67
Bolts-iOS 48
AFNetworking 39
Google-Mobile-Ads-SDK 38
Reachability (Apple) 38
Crashlytics 37
Flurry-iOS-SDK 31
CocoaPods 30
GoogleConversionTracking 29
@cabeca
cabeca / simulator_populator_xcode7
Last active April 16, 2020 09:18
This script removes and recreates all simulators in Xcode 7.
View simulator_populator_xcode7
#!/usr/bin/env ruby
require 'JSON'
device_types = JSON.parse `xcrun simctl list -j devicetypes`
runtimes = JSON.parse `xcrun simctl list -j runtimes`
devices = JSON.parse `xcrun simctl list -j devices`
devices['devices'].each do |runtime, runtime_devices|
runtime_devices.each do |device|
View _show-url-schemes.sh
/System/Library/Frameworks/CoreServices.framework/Versions/A/Frameworks/LaunchServices.framework/Versions/A/Support/lsregister -dump | grep -B6 bindings:.*:
@bittner
bittner / gnu-tools-for-mac.sh
Last active December 11, 2021 20:05
Cross-OS compatibility with GNU tools (readlink, sed, zcat, zless, zdiff, ...) for Mac OS X towards Linux
View gnu-tools-for-mac.sh
# DESCRIPTION OF PROBLEM: Implementations of sed, readlink, zcat, etc. are different on OS X and Linux.
# NOTE: Put this on top of your script using sed, readlink, zcat, etc. that should work alike on Mac OS X.
# cross-OS compatibility (greadlink, gsed, zcat are GNU implementations for OS X)
[[ `uname` == 'Darwin' ]] && {
which greadlink gsed gzcat > /dev/null && {
unalias readlink sed zcat
alias readlink=greadlink sed=gsed zcat=gzcat
} || {
echo 'ERROR: GNU utils required for Mac. You may use homebrew to install them: brew install coreutils gnu-sed'