Skip to content

Instantly share code, notes, and snippets.

View emyasnikov's full-sized avatar

Evgenij 'Warl' Myasnikov emyasnikov

  • Germany
View GitHub Profile
@krlozadan
krlozadan / PullWithoutHistoryInGit.md
Last active June 18, 2024 12:09
Pull from another repository without history using Git

Pull from another repository without history using Git

Ok, so lets contextualize ourselves

  • Let's say you have a main repo A which could be an open source project or a company project
  • Project A served as blueprint for your next project, B. So you either forked or cloned A and removed the .git folder to have a clean git history
  • You start working on project B as you would normally do

Now... at some point A changes and you want to pull those changes to B without getting the entire commit history. Maybe there's only 1 commit, maybe there's thousands.

@abhaywawale
abhaywawale / v-data-table-with-handle.vue
Created July 4, 2018 08:30
Where user can select the text and interact with the table
<template>
<v-container fluid>
<v-layout align-start justify-center>
<v-data-table :headers="headers" :items="desserts" hide-actions class="elevation-2">
<template slot="items" slot-scope="props">
<td class="handle" style="max-width: 28px;">::</td>
<td>{{ props.item.name }}</td>
<td class="text-xs-right">{{ props.item.calories }}</td>
<td class="text-xs-right">{{ props.item.fat }}</td>
<td class="text-xs-right">{{ props.item.carbs }}</td>
@Abhey
Abhey / Simple Client.c
Last active March 31, 2024 13:38
Simple client server chat system in C
#include <stdio.h>
#include <stdlib.h>
#include <unistd.h>
#include <fcntl.h>
#include <pthread.h>
#include <netinet/in.h>
#include <sys/socket.h>
#include <sys/types.h>
int main(){
@Jerakin
Jerakin / luacheck_std.luacheckrc
Last active April 29, 2021 22:33
Luacheck and Defold
return {
stds = {
defold = {
read_globals = {
"go", "gui", "msg", "url", "sys", "render", "factory", "particlefx", "physics", "sound", "sprite", "image",
"tilemap", "vmath", "matrix4", "vector3", "vector4", "quat", "hash", "hash_to_hex", "hashmd5", "pprint",
"iap", "facebook", "push", "http", "json", "spine", "zlib", "collectionfactory",
"__dm_script_instance__", "socket", "adtruth", "jit", "bit", "window", "webview", "profiler", "resource",
"collectionproxy", "label", "model", "timer", "zlib", "html5", "buffer", "crash", "bit32",
"RenderScriptConstantBuffer", "RenderScriptPredicate", "RenderScript", "GuiScript", "GuiScriptInstance"
@michaellihs
michaellihs / tmux-cheat-sheet.md
Last active June 22, 2024 15:52
tmux Cheat Sheet
@vinothkannans
vinothkannans / git-merge.md
Last active March 1, 2024 02:20
Syncing a fork or clone without history of remote commits
  • First fork or clone your remote git project
  • Delete existing history and commits by deleting .git folder
  • Add remote git project as upstream
  • Fetch the branches and their respective commits from the upstream repository. Commits to master will be stored in a local branch, upstream/master.
git fetch upstream
  • Check out your local master branch.
git checkout master
@AGulev
AGulev / swipe.lua
Last active November 22, 2021 15:54
adoptation of swipe-direction script by ScottPhillips https://github.com/ScottPhillips/swipe-direction/blob/master/swipe-direction.lua for Defold engine
local beginX
local beginY
local endX
local endY
local startTime
local xDistance
local yDistance
@phillipsharring
phillipsharring / Kernel.php
Last active October 9, 2023 13:11 — forked from kkiernan/MySqlDump.php
Laravel Artisan command to perform MySQL Dump using database connection information in the .env file. Posted 2016 Jan. Unsupported. Forked from https://gist.github.com/kkiernan/bdd0954d0149b89c372a
<?php
namespace App\Console;
use Illuminate\Console\Scheduling\Schedule;
use Illuminate\Foundation\Console\Kernel as ConsoleKernel;
class Kernel extends ConsoleKernel
{
/**
@psgganesh
psgganesh / default
Last active September 13, 2022 03:24
Simple lumen nginx conf
server {
listen 80 default_server;
listen [::]:80 default_server ipv6only=on;
listen 443 ssl;
root /var/www/lumen/public;
index index.php index.html index.htm;
server_name server_domain_or_IP;
@feryardiant
feryardiant / install_libsass.sh
Last active June 26, 2021 20:09
Easy way to Install libsass & sassc in Ubuntu, `curl -sSL http://git.io/vnxQ4 | sudo bash`
#!/bin/bash
# Based on https://gist.github.com/edouard-lopez/503d40a5c1a49cf8ae87
set -e
# Installing dependencies
apt-get -q -y install build-essential automake libtool git
buildDir="/tmp/sass-build"