First you need the 'xsel' package.
$> pacman -S xsel
Then create aliases.
alias pbcopy='xsel --clipboard --input'
alias pbpaste='xsel --clipboard --output'
| var http = require('http'); | |
| var httpProxy = require('http-proxy'); | |
| var proxy = httpProxy.createProxyServer(); | |
| http.createServer(function(req, res){ | |
| if(/^\/api/.test(req.url)){ | |
| req.url = req.url.replace(/^\/api/, ""); | |
| proxy.web(req, res, {target:'http://localhost:7889'}); | |
| } else { |
| $.fn.crossDomainRequest = function(url, method, data, fn) { | |
| var self = this; | |
| var receiver = self.attr('src').replace(/\/.*$/, '').replace(/^https?::\/\//, ''); | |
| function get(event) { | |
| if (event.origin.match(receiver)) { | |
| // event.data is response from POST | |
| fn(event.data); | |
| } | |
| } | |
| if (window.addEventListener){ |