Skip to content

Instantly share code, notes, and snippets.

View Vesely's full-sized avatar

David Veselý Vesely

View GitHub Profile
@Vesely
Vesely / install-rozjed-localhost.sh
Last active January 19, 2026 13:15
install-rozjed-localhost.sh
#!/bin/bash
# Run Project on Localhost installer
# https://gist.githubusercontent.com/Vesely/5bf2910820031dc3ee2b897b49b8ff61/raw/3f376392c94b6fd0ca1ae6a53b0ccefb0bfd3760/rozjed-localhost.md
# Install: curl -fsSL GIST_RAW_URL | bash
set -e
# Colors (only if stdout is a TTY)
if [ -t 1 ]; then

Run Project on Localhost

Detect project type and run on localhost.

Steps

  1. Detect project type

    • package.json → Node.js, requirements.txt/pyproject.toml → Python
  2. Detect package manager (Node.js)

@Vesely
Vesely / gist:6f97abd4126508dd4c58cc2df9b3787d
Last active October 25, 2021 08:45
TypeError: Cannot read property 'split' of undefined

Error: TypeError: Cannot read property 'split' of undefined

Solution: Change npm depencency nuxt-svg to @nuxtjs/svg

@Vesely
Vesely / zapati
Created May 11, 2020 17:03
Shoptet - přesměrování zákazníka do košíku po přidání položky do košíku
<script>
var redirectToCard = function() {
if (!document.body.classList.contains('ajax-pending')) {
setTimeout(function() {
window.location.href = '/kosik/';
}, 500);
} else {
setTimeout(redirectToCard, 500);
}
};
@Vesely
Vesely / zeit-now-vercel-dns-g-suite-setup.md
Last active November 21, 2020 17:27 — forked from jaydenseric/zeit-now-g-suite-setup.md
Zeit Now Vercel DNS: G Suite and Improve MX setup

Run each of the following lines, replacing yourdomain.com and codehere with your details:

now dns add yourdomain.com @ TXT google-site-verification=codehere
now dns add yourdomain.com @ MX ASPMX.L.GOOGLE.COM 1
now dns add yourdomain.com @ MX ALT1.ASPMX.L.GOOGLE.COM 5
now dns add yourdomain.com @ MX ALT2.ASPMX.L.GOOGLE.COM 5
now dns add yourdomain.com @ MX ALT3.ASPMX.L.GOOGLE.COM 10
now dns add yourdomain.com @ MX ALT4.ASPMX.L.GOOGLE.COM 10
@Vesely
Vesely / .editorconfig
Created November 1, 2018 19:31
.editorconfig
root = true
[*]
indent_style = space
indent_size = 2
charset = utf-8
trim_trailing_whitespace = true
insert_final_newline = true
end_of_line = lf
# editorconfig-tools is unable to ignore longs strings or urls
@Vesely
Vesely / bookmark.js
Last active September 6, 2018 14:45
Trello - Get last ID
window.liff = window.liff || {};
window.liff.calcLastId = () => {
if (!document.querySelector('.js-last-id')) {
const headerBtns = document.querySelector('.board-header-btns.mod-left');
if (headerBtns) {
const lastIdElement = document.createElement("div");
lastIdElement.className = "js-last-id board-header-btn";
headerBtns.appendChild(lastIdElement);
} else {
@Vesely
Vesely / scroll-to.js
Created September 8, 2017 12:48
Stroll To Y (vanilla js)
/*
* Scroll To
*/
// first add raf shim
// http://www.paulirish.com/2011/requestanimationframe-for-smart-animating/
window.requestAnimFrame = (function(){
return window.requestAnimationFrame ||
window.webkitRequestAnimationFrame ||
window.mozRequestAnimationFrame ||
function( callback ){
Duplikace:
git clone --bare https://github.com/vaadin/vaadin-upload.git
cd public-repo.git
git push --mirror https://github.com/liffstudio/vaadin-upload.git
Přidání modulu:
git submodule add https://github.com/liffstudio/vaadin-upload.git vaadin-upload
@Vesely
Vesely / gist:b28f33dab0b0c389d0feede54b71f721
Created November 13, 2016 13:29
Marge a git branch to master
git checkout master
git pull origin master
git merge TEST
git push origin master