Skip to content

Instantly share code, notes, and snippets.

View NoNamePro0's full-sized avatar
:octocat:
Githubing

No Name Pro NoNamePro0

:octocat:
Githubing
  • Germany
View GitHub Profile
@NoNamePro0
NoNamePro0 / themes.js
Last active April 21, 2020 13:49
Get Theme from URL Parameter and enable CSS theme
var head = document.getElementsByTagName('HEAD')[0];
const queryString = window.location.search;
const urlParams = new URLSearchParams(queryString);
const theme = urlParams.get('theme')
var link = document.createElement('link');
link.rel = 'stylesheet';
link.type = 'text/css';
@NoNamePro0
NoNamePro0 / start.sh
Last active June 1, 2020 06:58
Run a command in the background witch automatically rerun
#!/bin/bash
name='yourName'
command="yourCommand" # Use ${0%/*} to go in the folder from the start.sh
timeout='120'
script_path="${0}"
if [[ $1 == "--non-background" ]]
then
@NoNamePro0
NoNamePro0 / gradle.sh
Created June 18, 2020 12:12
Install Gradle
#!/bin/bash
GRADLE_VERSION=6.5
wget "https://services.gradle.org/distributions/gradle-$GRADLE_VERSION-bin.zip" -P /gradle
unzip /gradle/gradle-$GRADLE_VERSION-bin.zip -d /gradle/
export PATH=$PATH:/gradle/gradle-$GRADLE_VERSION/bin
@NoNamePro0
NoNamePro0 / _nginx-default.conf
Last active August 9, 2020 17:55
NGINX default server configuration
# THIS GIST IS A SMALL DIRECTORY OF THE DEFAULT `/etc/nginx`