osascript -e "set volume with output muted"
osascript -e "set volume without output muted"
tee -a /etc/dnsmasq.conf << EOF
###################################
# TFTP Server custom configutation
####################################
enable-tftp
tftp-root=/root/tftp
# Architecture list
# https://www.iana.org/assignments/dhcpv6-parameters/dhcpv6-parameters.xhtml#processor-architecture
Predictable network interface device names based on:
- firmware/bios-provided index numbers for on-board devices
- firmware-provided pci-express hotplug slot index number
- physical/geographical location of the hardware
- the interface's MAC address
alias www="python -m SimpleHTTPServer 8000" | |
alias ssh_via_proxy='ssh -o "ProxyCommand nc -X 5 -x localhost:6000 %h %p"' | |
alias git_merge_up="git merge upstream/master" | |
alias proxy_on='networksetup -setsocksfirewallproxystate "Wi-Fi" on' | |
alias proxy_off='networksetup -setsocksfirewallproxystate "Wi-Fi" off' | |
# Perl SED | |
# | |
alias psed="perl -pe" |
XVFB=/usr/bin/Xvfb | |
XVFBARGS=":1 -screen 0 1024x768x24 -ac +extension GLX +render -noreset" | |
PIDFILE=/var/run/xvfb.pid | |
case "$1" in | |
start) | |
echo -n "Starting virtual X frame buffer: Xvfb" | |
start-stop-daemon --start --quiet --pidfile $PIDFILE --make-pidfile --background --exec $XVFB -- $XVFBARGS | |
echo "." | |
;; | |
stop) |
Dictionary is the application, which shall be adjusted to the position {0, 20} and to the size {1280, 800}.
Note that this is the size of the plain window without a shadow. If you do a screenshot, you can omit a shadow by holding the ⌥ [option] key.
tell application "System Events"
set ssProcess to first process whose name is "Dictionary"
tell ssProcess
tell first window
set position to {0, 20}
#pragma mark - | |
#pragma mark NSTableViewDataSource | |
- (void)tableView:(NSTableView *)tableView draggingSession:(NSDraggingSession *)session willBeginAtPoint:(NSPoint)screenPoint forRowIndexes:(NSIndexSet *)rowIndexes | |
{ | |
// configure the drag image | |
// we are only dragging one item | |
NSTableCellView *cellView = [self.columnsTableView viewAtColumn:0 row:rowIndexes.firstIndex makeIfNecessary:NO]; | |
if (cellView) { | |