Skip to content

Instantly share code, notes, and snippets.

View dorlugasigal's full-sized avatar
πŸ‘½
Hello World!

Dor Lugasi-Gal dorlugasigal

πŸ‘½
Hello World!
View GitHub Profile
@dorlugasigal
dorlugasigal / install-zsh-wsl.sh
Last active June 18, 2026 17:37
DLG Zsh Environment β€” WSL Setup Script (no Homebrew)
#!/bin/bash
# ══════════════════════════════════════════════════════════════
# DLG Zsh Environment β€” WSL Setup Script (no Homebrew)
# ══════════════════════════════════════════════════════════════
# Usage: chmod +x install-zsh-wsl.sh && ./install-zsh-wsl.sh
#
# One-liner (run from anywhere):
# bash <(curl -sL <YOUR_GIST_RAW_URL>)
# ══════════════════════════════════════════════════════════════
set -e
@dorlugasigal
dorlugasigal / install-zsh-setup 1.sh
Last active June 24, 2026 08:45
DLG Zsh Environment - Mac Setup Script
DLG Zsh Environment - Mac Setup Script
#!/bin/bash
# ══════════════════════════════════════════════════════════════
# DLG Zsh Environment β€” Mac Setup Script
# ══════════════════════════════════════════════════════════════
# Usage: chmod +x install-zsh-setup.sh && ./install-zsh-setup.sh
#
# One-liner (run from anywhere):
# bash <(curl -sL https://gist.githubusercontent.com/dorlugasigal/97d4f7f8d4f0c1acc31a94a2b103d55d/raw/install-zsh-setup%201.sh)
@dorlugasigal
dorlugasigal / install-pwsh-setup.ps1
Last active March 1, 2026 00:50
DLG PowerShell Environment - Windows Setup Script
#Requires -Version 5.1
# ══════════════════════════════════════════════════════════════
# DLG PowerShell Environment β€” Windows Setup Script
# ══════════════════════════════════════════════════════════════
# Usage: Run in PowerShell as Administrator (for font install)
# Set-ExecutionPolicy Bypass -Scope Process -Force
# .\install-pwsh-setup.ps1
#
# One-liner (run from anywhere):
# Set-ExecutionPolicy Bypass -Scope Process -Force; iex (iwr -UseBasicParsing 'https://gist.githubusercontent.com/dorlugasigal/15ae6fa54e1bd03c981c446cc394f85f/raw/install-pwsh-setup.ps1').Content
@dorlugasigal
dorlugasigal / Program.cs
Created January 9, 2025 07:36
LINQ Deep Dive code
using System.Collections;
using BenchmarkDotNet.Attributes;
using BenchmarkDotNet.Running;
// Console.WriteLine($"LINQ: {Enumerable.Select(source, i => i * 2).Sum()}");
// Console.WriteLine($"COMPILER: {SelectCompiler(source, i => i * 2).Sum()}");
// Console.WriteLine($"MANUAL: {SelectManual(source, i => i * 2).Sum()}");
// FOR PROFILING
@dorlugasigal
dorlugasigal / gist:f7c747e5fc8db020433e96feeb5ed50f
Created February 21, 2023 10:08
very simple bashrc aliases for a new linux based env
# personalizedΒ 
alias g='git'
alias main='git checkout main'
alias master='git checkout master'alias lc='clear && ls'
alias cl='clear && ls'
alias gb='git checkout -b'
alias gitreset='git checkout main; git branch | grep -v \* | xargs git branch -D'
alias commit='comm'
comm(){
git add .;Β Β Β  git commit -m "$@"; git push -u origin HEAD
@dorlugasigal
dorlugasigal / $PROFILE
Last active February 7, 2025 00:33
my PowerShell $PROFILE imports
#### user interface ####
Import-Module Terminal-Icons
oh-my-posh --init --shell pwsh --config 'C:\Users\dorlugasigal\OhMyPoshThemes\dlg.omp.json' | Invoke-Expression
#### common aliases ####
Set-Alias g git
Set-Alias vim nvim
Set-Alias vi nvim
@dorlugasigal
dorlugasigal / dlg.omp.json
Last active August 9, 2023 15:42
Oh My Posh theme
{
"$schema": "https://raw.githubusercontent.com/JanDeDobbeleer/oh-my-posh/main/themes/schema.json",
"blocks": [
{
"alignment": "left",
"segments": [
{
"background": "#ff479c",
"foreground": "#ffffff",
"leading_diamond": "\ue0b6",
@dorlugasigal
dorlugasigal / install-nerdfonts.ps1
Created June 29, 2022 07:43 — forked from daretodave/install-nerdfonts.ps1
nerd-fonts windows install script. accepts optional argument for the font to install, otherwise all patched-fonts are installed
# run this with an argument to install a nerdfont on windows
# run this with no arguments to install all fonts
# font name, as seen on https://www.nerdfonts.com/font-downloads
param(
[Parameter(Mandatory=$False, Position=0, ValueFromPipeline=$false)]
[System.String]
$fontTarget="*"
)
# build temp directory for git clone