Skip to content

Instantly share code, notes, and snippets.

View shaunbharat's full-sized avatar

Shaun Bharat shaunbharat

  • Canada
  • 20:54 (UTC -04:00)
View GitHub Profile
@xoxefdp
xoxefdp / win10-remove-docker.ps1
Created February 28, 2018 11:04
How to completely remove docker on Windows 10
# https://success.docker.com/article/How_to_completely_remove_Docker_in_Windows_10
$ErrorActionPreference = "SilentlyContinue"
kill -force -processname 'Docker for Windows', com.docker.db, vpnkit, com.docker.proxy, com.docker.9pdb, moby-diag-dl, dockerd
try {
./MobyLinux.ps1 -Destroy
} Catch {}
@mutin-sa
mutin-sa / Top_Public_Time_Servers.md
Last active July 22, 2025 13:46
List of Top Public Time Servers

Google Public NTP [AS15169]:

time.google.com

time1.google.com

time2.google.com

time3.google.com

@gaearon
gaearon / modern_js.md
Last active July 20, 2025 07:39
Modern JavaScript in React Documentation

If you haven’t worked with JavaScript in the last few years, these three points should give you enough knowledge to feel comfortable reading the React documentation:

  • We define variables with let and const statements. For the purposes of the React documentation, you can consider them equivalent to var.
  • We use the class keyword to define JavaScript classes. There are two things worth remembering about them. Firstly, unlike with objects, you don't need to put commas between class method definitions. Secondly, unlike many other languages with classes, in JavaScript the value of this in a method [depends on how it is called](https://developer.mozilla.org/en-US/docs/Web/Jav
@Lonami
Lonami / mc-ping.py
Last active June 24, 2024 17:35
Python Minecraft Server Pinger
import struct
import socket
import base64
import json
import sys
class Server:
def __init__(self, data):
self.description = data.get('description')
@NaniteFactory
NaniteFactory / lpcwstr.go
Last active September 21, 2023 00:12 — forked from icholy/lpcwstr.go
Convert the UTF16 Wide String (WSTR) from/to plain Go string.
package lpcwstr
// #include <windows.h>
// #include <wchar.h>
// #include <WinNT.h>
import "C"
import (
"unicode/utf16"
"unsafe"
@qoomon
qoomon / conventional-commits-cheatsheet.md
Last active July 22, 2025 17:48
Conventional Commits Cheatsheet
@luismts
luismts / GitCommitBestPractices.md
Last active July 22, 2025 15:04
Git Tips and Git Commit Best Practices

Git Commit Best Practices

Basic Rules

Commit Related Changes

A commit should be a wrapper for related changes. For example, fixing two different bugs should produce two separate commits. Small commits make it easier for other developers to understand the changes and roll them back if something went wrong. With tools like the staging area and the ability to stage only parts of a file, Git makes it easy to create very granular commits.

Commit Often

Committing often keeps your commits small and, again, helps you commit only related changes. Moreover, it allows you to share your code more frequently with others. That way it‘s easier for everyone to integrate changes regularly and avoid having merge conflicts. Having large commits and sharing them infrequently, in contrast, makes it hard to solve conflicts.

6.8.1 Package Names

Names of packages that are to be made widely available should be formed as described in §7.7. Such names are always qualified names whose first identifier consists of two or three lowercase letters that name an Internet domain, such as com, edu, gov, mil, net, org, or a two-letter ISO country code such as uk or jp. Here are examples of hypothetical unique names that might be formed under this convention:

com.JavaSoft.jag.Oak
org.npr.pledge.driver
uk.ac.city.rugby.game
@yougg
yougg / detectrun.go
Created June 20, 2019 13:43
Detect if windows golang executable file is running via double click or from cmd/shell terminator
// +build windows
//go:generate go build -ldflags "-s -w -extldflags '-static'" $GOFILE
package main
import (
"fmt"
"syscall"
"unsafe"
)
@cptpiepmatz
cptpiepmatz / GetSnapmaticPictures.bat
Last active April 7, 2023 16:42
A little tool to extract the GTAV Snapmatic pictures into your pictures folder in your user folder.
@echo off
rem Version 1.1.1
set picturePath="%UserProfile%\Pictures\GTA Snapmatic"
set convertScript="%UserProfile%\Pictures\GTA Snapmatic\ConvertSnapmaticToJpg.ps1"
md %picturePath%
echo Copying Snapmatic Pictures to Pictures Folder
echo ---------------------------------------------