Skip to content

Instantly share code, notes, and snippets.

Pipeline Steps logs

✅ "echo /file.txt" Failed

Step took 152 ms.

+ echo /file.txt
/file.txt
@scheibinger
scheibinger / protractor.js
Last active November 9, 2016 00:51
protractor snippets
browser.waitForAngular();
browser.sleep(500);
// within a test:
browser.takeScreenshot().then(function (png) {
writeScreenShot(png, 'main.png');
});
browser.manage().logs()
@scheibinger
scheibinger / handy regex
Created April 27, 2016 03:33
handy regex patterns
//transform query string into an object
var queryString = {};
anchor.href.replace(
new RegExp("([^?=&]+)(=([^&]*))?", "g"),
function($0, $1, $2, $3) { queryString[$1] = $3; }
);
@scheibinger
scheibinger / proxy_nginx.sh
Created April 13, 2016 04:43 — forked from rdegges/proxy_nginx.sh
Create a HTTP proxy for jenkins using NGINX.
sudo aptitude -y install nginx
cd /etc/nginx/sites-available
sudo rm default
sudo cat > jenkins
upstream app_server {
server 127.0.0.1:8080 fail_timeout=0;
}
server {
listen 80;
@scheibinger
scheibinger / bash_cheatsheet.md
Last active April 1, 2016 17:54
Useful bash commands
#show disk usage of folders
find . -type d -maxdepth 1 -exec du -hcs {} \; | grep "./"	

#unzip recursively
find . -name "*.zip" -exec unzip {} \; -exec /bin/rm {} \;	

#curl POST data and newlines
cat /tmp/mm.txt | curl -d @- http://localhost:3000/message/new
cat /tmp/mm.txt | lwp-request -m POST http://localhost:7600/edges/2269000	
@scheibinger
scheibinger / tmux-cheatsheet.markdown
Created December 31, 2015 19:41 — forked from MohamedAlaa/tmux-cheatsheet.markdown
tmux shortcuts & cheatsheet

tmux shortcuts & cheatsheet

start new:

tmux

start new with session name:

tmux new -s myname
@scheibinger
scheibinger / good-mocha-test.js
Last active December 16, 2015 01:38
Good mocha test
//describe what are you testing: given
describe('button widget', function(){
//describe the aspect of object that you are testing: when
describe('when button is clicked', function(){
//verify the expectation: then
it('onClickHandler should be called ', function(){
expect(onClickHandler).to.have.been.called
})
})
});
@scheibinger
scheibinger / RxJS-two-way-binding-example.markdown
Created October 28, 2014 22:55
A Pen by Radoslaw Scheibinger.
@scheibinger
scheibinger / git-tips.sh
Created March 11, 2014 17:56
git-tips.sh
#remove untracked files:
git clean -f
#unstage file
git reset HEAD file