Skip to content

Instantly share code, notes, and snippets.

View viktor-podzigun's full-sized avatar
๐ŸŒ“
Don't work hard - work smart ๐Ÿ˜‰

Viktor Podzigun viktor-podzigun

๐ŸŒ“
Don't work hard - work smart ๐Ÿ˜‰
View GitHub Profile
@privatenumber
privatenumber / typescript-v5-to-v6.md
Created February 24, 2026 13:21
TypeScript 5.x to 6.0 Migration Guide

TypeScript 5.x to 6.0 Migration Guide

TypeScript 6.0 is a transition release bridging 5.9 and the forthcoming 7.0 (a native Go port). Most changes are new defaults and deprecations preparing for 7.0. Here is what you need to do:

Most projects need these tsconfig changes:

{
    "compilerOptions": {
        "types": ["node"],           // @types are no longer auto-discovered (see ยง1.6)
// Slightly modified version of: https://github.com/es-shims/RegExp.escape/blob/main/test/tests.js
import test from 'node:test';
import assert from 'node:assert/strict';
import {regExpEscape as escape} from './regexp-escape.mjs';
const forEach = (arrayLike, callback) => Array.prototype.forEach.call(arrayLike, callback);
const inspect = String;
test('strings', function (st) {
@MateuszKubuszok
MateuszKubuszok / speeches.md
Last active May 16, 2023 14:12
My public speeches, presentations and and stuff

My public speeches

Actually, more like hall of shame because I cannot watch/listen to myself without cringe, but in this time and age everyone has to be a salesman. Well, not really, but it kind of help with self-development and getting confidence, so whatever. Remember kids! You don't have to be competent to be a public speaker! (Or write a book. Or blog. Or OSS. Or get a job.)

Optimizing Heavy Web Service presentation

@TheSherlockHomie
TheSherlockHomie / RenewExpiredGPGkey.md
Created January 3, 2021 16:36
Updating expired GPG keys and backing them up ๐Ÿ”‘๐Ÿ”๐Ÿ’ป

Updating expired GPG keys and their backup ๐Ÿ”‘๐Ÿ”๐Ÿ’ป

I use a GPG key to sign my git commits.

An error like this one might be a sign of an expired GPG key.

error: gpg failed to sign the data fatal: failed to write commit object

Fibers

Fibers are an abstraction over sequential computation, similar to threads but at a higher level. There are two ways to think about this model: by example, and abstractly from first principles. We'll start with the example.

(credit here is very much due to Fabio Labella, who's incredible Scala World talk describes these ideas far better than I can)

Callback Sequentialization

Consider the following three functions

git config --global alias.br "for-each-ref --sort=committerdate refs/heads/ --format='%(HEAD) %(color:yellow)%(refname:short)%(color:reset) - %(color:red)%(objectname:short)%(color:reset) - %(contents:subject) - %(authorname) (%(color:green)%(committerdate:relative)%(color:reset))'"

Using JSDOC-Based TypeScript

Get Started

Choose your editor

  • WebStorm, Rider
    • Partial support, not enough intelli hints
    • Toggle on TypeScript language service
  • VSCode
@japgolly
japgolly / upgrade.md
Last active April 26, 2022 02:55
Scala 2.13 migration notes

scalafix

addSbtPlugin("ch.epfl.scala" % "sbt-scalafix" % "0.9.13")
import scalafix.sbt.ScalafixPlugin.autoImport.{scalafixDependencies, scalafixSemanticdb}

scalafixDependencies in ThisBuild += "org.scala-lang.modules" %% "scala-collection-migrations" % "2.1.4",
@oseme-techguy
oseme-techguy / Correct_GnuPG_Permission.sh
Last active March 31, 2026 20:57
This fixes the " gpg: WARNING: unsafe permissions on homedir '/home/path/to/user/.gnupg' " error while using Gnupg .
#!/usr/bin/env bash
# To fix the " gpg: WARNING: unsafe permissions on homedir '/home/path/to/user/.gnupg' " error
# Make sure that the .gnupg directory and its contents is accessibile by your user.
chown -R $(whoami) ~/.gnupg/
# Also correct the permissions and access rights on the directory
chmod 600 ~/.gnupg/*
chmod 700 ~/.gnupg
@cb372
cb372 / gist:66bc0ffdfec87744c473355a34ac61f3
Created January 3, 2019 21:26
Pushing commits to someone else's PR
# Terminology
their_username = the GitHub username of the contributor who submitted the PR
their_branch = the name of the branch they used to submit the PR
repo_name = the name of your GitHub repository
# First add their fork as a remote
git remote add $their_username git@github.com:${their_username}/${repo_name}.git
# Then fetch it
git fetch $their_username