Skip to content

Instantly share code, notes, and snippets.

View YasinKuralay's full-sized avatar

Yasin S. Kuralay YasinKuralay

  • Datatrain GmbH
  • Berlin, Germany
View GitHub Profile
@YasinKuralay
YasinKuralay / branch-renaming.git
Created October 12, 2021 07:58
Git Branch Stuff
Hinweis: Als Name für den initialen Branch wurde 'master' benutzt. Dieser
Hinweis: Standard-Branchname kann sich ändern. Um den Namen des initialen Branches
Hinweis: zu konfigurieren, der in allen neuen Repositories verwendet werden soll und
Hinweis: um diese Warnung zu unterdrücken, führen Sie aus:
Hinweis:
Hinweis: git config --global init.defaultBranch <Name>
Hinweis:
Hinweis: Häufig gewählte Namen statt 'master' sind 'main', 'trunk' und
Hinweis: 'development'. Der gerade erstellte Branch kann mit diesem Befehl
Hinweis: umbenannt werden:
@YasinKuralay
YasinKuralay / button.css
Last active October 4, 2021 14:52
Remove Button Styles
button {
background: transparent;
box-shadow: 0px 0px 0px transparent;
border: 0px solid transparent;
text-shadow: 0px 0px 0px transparent;
}
button:hover {
background: transparent;
box-shadow: 0px 0px 0px transparent;
@YasinKuralay
YasinKuralay / height.js
Last active June 2, 2021 07:29
JS Document height
// Calculation on load because otherwise IOS devices return an unreliable height variable ( different values at different places )
window.addEventListener("load", () => {
// See stackoverflow post https://stackoverflow.com/a/1147768
let height = Math.max(
document.body.scrollHeight,
document.body.offsetHeight,
html.clientHeight,
html.scrollHeight,
html.offsetHeight
);
@YasinKuralay
YasinKuralay / wow.go
Created May 17, 2021 15:24
GOLANG WWs
// Since we know the length of out is the same as in, isn't it better
// to pre-create out with a fixed length rather than calling append in
// a loop? I think append will double its capacity when needed.
@YasinKuralay
YasinKuralay / script.js
Created May 11, 2021 12:42
Disable CSS Transitions on Window Resize
/* PREVENT TRANSITIONS ON WINDOW RESIZE
taken from https://stackoverflow.com/questions/38526764/disable-css-transitions-on-window-resize */
<script>
(function() {
const classes = document.body.classList;
let timer = 0;
window.addEventListener('resize', function () {
if (timer) {
clearTimeout(timer);
timer = null;
@YasinKuralay
YasinKuralay / no-text-select.css
Created May 11, 2021 10:02
No Text Select CSS
.unselectable {
-moz-user-select: none;
-webkit-user-select: none;
-ms-user-select: none;
user-select: none;
}
.all {
-moz-user-select: all;
-webkit-user-select: all;
(ubuntu)
apt-get update
[https://nginx.org/en/download.html] choose url from here and do: wget [url]
tar -zxvf nginx-...tar.gz
cd nginx... [non-tar version]
./configure