This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
# print an anchor subset (r, n or A) | |
function pfprint() { | |
# avoid trusting PATH and . | |
/usr/bin/sudo pfctl -a "$2" -s"$1" 2>/dev/null | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
USE phabricator_user; | |
-- create LDAP mappings for unmapped users | |
-- this query uses a subselect due to the way MySQL reacts to UUID() being | |
-- wrapped in REPLACE() (returns the same UUID for all rows) | |
-- WARNING: make sure user.userName maps to LDAP usernames, otherwise | |
-- user_externalaccount.accountID needs to be modified for those users | |
-- where it doesn't. alternatively, use Phabricator's change username | |
-- utility in People app to change those users' usernames before running | |
INSERT INTO user_externalaccount |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
mingw32-gcc select_ws.c -Wl,-lws2_32 -g -pedantic -Wall -W -Wpointer-arith -Wwrite-strings -Wunused -Wshadow -Winline -Wnested-externs -Wmissing-declarations -Wmissing-prototypes -Wno-long-long -Wfloat-equal -Wno-multichar -Wsign-compare -Wundef -Wno-format-nonliteral -Wendif-labels -Wstrict-prototypes -Wdeclaration-after-statement -Wstrict-aliasing=3 -Wcast-align -Wtype-limits -Wold-style-declaration -Wmissing-parameter-type -Wempty-body -Wclobbered -Wignored-qualifiers -Wconversion -Wno-sign-conversion -Wvla -Wno-pedantic-ms-format -Wno-system-headers -o select_ws.exe |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Based on @berenm's pull request https://github.com/quarnster/SublimeClang/pull/135 | |
# Create the database with cmake with for example: cmake -DCMAKE_EXPORT_COMPILE_COMMANDS=ON .. | |
# or you could have set(CMAKE_EXPORT_COMPILE_COMMANDS ON) in your CMakeLists.txt | |
# Usage within SublimeClang: | |
# "sublimeclang_options_script": "python ${home}/code/cmake_options_script.py ${project_path:build}/compile_commands.json", | |
import re | |
import os | |
import os.path |