Portions taken from http://www.cs.utexas.edu/~mitra/csSpring2011/cs327/cx_mac.html (in case that link ever dies.)
Assume you've got homebrew installed.
Download the following files from Oracle
| #include <sys/socket.h> | |
| #include <sys/types.h> | |
| #include <netinet/in.h> | |
| #include <arpa/inet.h> | |
| #include <netdb.h> | |
| #include <unistd.h> | |
| #include <string.h> | |
| #include <iostream> | |
| #include <stdarg.h> | |
| #include <stdio.h> |
| #include "StdAfx.h" | |
| #include <Setupapi.h> | |
| #pragma comment(lib, "Setupapi.lib") | |
| #include "SerialPort.h" | |
| SerialPort::SerialPort(void) : end_of_line_char_('\n') | |
| { | |
| } |
| -- show running queries (pre 9.2) | |
| SELECT procpid, age(clock_timestamp(), query_start), usename, current_query | |
| FROM pg_stat_activity | |
| WHERE current_query != '<IDLE>' AND current_query NOT ILIKE '%pg_stat_activity%' | |
| ORDER BY query_start desc; | |
| -- show running queries (9.2) | |
| SELECT pid, age(clock_timestamp(), query_start), usename, query | |
| FROM pg_stat_activity | |
| WHERE query != '<IDLE>' AND query NOT ILIKE '%pg_stat_activity%' |
Portions taken from http://www.cs.utexas.edu/~mitra/csSpring2011/cs327/cx_mac.html (in case that link ever dies.)
Assume you've got homebrew installed.
Download the following files from Oracle
Hi:
perl -e 'print "hello world!\n"'
A simple filter:
perl -ne 'print if /REGEX/'
Filter out blank lines (in place):
Ruby는 즐거운 언어입니다. Ruby를 사용하다보면 매뉴얼에도 나와있지 않은 '작은 발견'을 만나게 됩니다. 이러한 '발견'은 프로그램의 질이나
| #!/bin/sh | |
| # | |
| # i3blocks integration with dunst. | |
| # Author: Vivien Didelot <vivien.didelot@gmail.com> | |
| # | |
| # dunst caches a notification and signals i3blocks. | |
| # i3blocks catches the signal and prints the cached notification. | |
| # | |
| # Put this rule at the end of your ~/.config/dunst/dunstrc: | |
| # |
| #!/usr/bin/env python | |
| # cb-aerosnap: | |
| # A script for adding aero style window snapping to Openbox. | |
| # Written for CrunchBang Linux <http://crunchbang.org/> | |
| # by Philip Newborough <corenominal@corenominal.org> | |
| # ---------------------------------------------------------------------- | |
| # License: | |
| # DO WHAT THE FUCK YOU WANT TO PUBLIC LICENSE | |
| # Version 2, December 2004 | |
| # |
| // Example of how to use boost::asio::async_result | |
| #include <iostream> | |
| #include <boost/asio.hpp> | |
| #if BOOST_VERSION >= 106600 | |
| template<typename CompletionToken> | |
| typename boost::asio::async_result | |
| <CompletionToken, void(boost::system::error_code, std::string)>::return_type |