Skip to content

Instantly share code, notes, and snippets.

Avatar

Tien Tran coolersport

View GitHub Profile
View jenkins.js
var openConsole = function(e) {
window.location = this.href+'console';
e.preventDefault();
return false;
};
var updateAllBuildLinks = function() {
// change default build link to console log
var es = document.querySelectorAll('a[href*="job/"]');
[].forEach.call(es, function(e) {
@coolersport
coolersport / .docker-private-registry-with-read-write-control.md
Created Nov 7, 2017
Run docker private registry with read/write access control
View .docker-private-registry-with-read-write-control.md
View coolersport.theme.bash
#!/usr/bin/env bash
# based on minimal theme
dark_grey="\[$(tput setaf 8)\]"
SCM_THEME_PROMPT_PREFIX="${dark_grey}[${bold_orange}"
SCM_THEME_PROMPT_SUFFIX="${normal}${dark_grey}]"
SCM_THEME_PROMPT_DIRTY=" ${red}"
SCM_THEME_PROMPT_CLEAN=" ${green}"
@coolersport
coolersport / jre8_linux.txt
Last active Jan 22, 2018
Latest Oracle JRE for Linux
View jre8_linux.txt
http://download.oracle.com/otn-pub/java/jdk/8u161-b12/2f38c3b165be4555a1fa6e98c45e0808/jdk-8u161-linux-x64.tar.gz
View Remove all git tags
#Delete local tags.
git tag -l | xargs git tag -d
#Fetch remote tags.
git fetch
#Delete remote tags.
git tag -l | xargs git push --delete origin
#Delete local tasg.
git tag -l | xargs git tag -d
@coolersport
coolersport / Repeat.java
Last active Aug 8, 2018 — forked from fappel/Repeat.java
JUnit 4 TestRule to run a test repeatedly for a specified amount of repetitions
View Repeat.java
import static java.lang.annotation.ElementType.METHOD;
import static java.lang.annotation.RetentionPolicy.RUNTIME;
import java.lang.annotation.Retention;
import java.lang.annotation.Target;
/**
* <p>
* Repeat annotation to be applied at the test method level to indicate how many time the test method to be executed
* repeatedly.
@coolersport
coolersport / aspose_words_encoding_issues.md
Last active Aug 27, 2015
Aspose Words output incorrect unicode characters
View aspose_words_encoding_issues.md

With the same code base, Aspose Words renders documents with unicode characters properly on Linux but not Windows. It may be related to encoding set in system properties.

Verify that the following system properties are set as below:

-Dsun.jnu.encoding=UTF-8
-Dfile.encoding=UTF-8
You can’t perform that action at this time.