Skip to content

Instantly share code, notes, and snippets.

View nascarsayan's full-sized avatar
🎯
Focusing

Sayan Naskar nascarsayan

🎯
Focusing
  • Microsoft
  • Kolkata, India
View GitHub Profile
@nascarsayan
nascarsayan / iterm_profile.json
Created January 1, 2024 06:29
iterm_profile
{
"Ansi 4 Color" : {
"Red Component" : 0.035294119268655777,
"Color Space" : "sRGB",
"Blue Component" : 0.85490196943283081,
"Alpha Component" : 1,
"Green Component" : 0.4117647111415863
},
"Tags" : [
@nascarsayan
nascarsayan / PowerShellTaskRunner.cs
Created June 16, 2022 05:36 — forked from rjmholt/PowerShellTaskRunner.cs
Examples of how to run PowerShell with a runspace pool and async Tasks
using System;
using System.Collections.Generic;
using System.Collections.ObjectModel;
using System.IO;
using System.Management.Automation;
using System.Management.Automation.Runspaces;
using System.Reflection;
using System.Threading.Tasks;
/// <summary>
@nascarsayan
nascarsayan / cpp.json
Last active March 19, 2022 05:28
VSCode Snippets
{
"cpbasic": {
"prefix": "cpbasic",
"description": "",
"body": [
"#include <bits/stdc++.h>",
"using namespace std;",
"#pragma region header__",
"",
"#pragma region aliases___",
@nascarsayan
nascarsayan / vscode-launch-operator.json
Last active January 4, 2022 04:43
Debugging operator inside VSCode
{
// Use IntelliSense to learn about possible attributes.
// Hover to view descriptions of existing attributes.
// For more information, visit: https://go.microsoft.com/fwlink/?linkid=830387
"version": "0.2.0",
"configurations": [
{
"name": "VMM",
"type": "go",
"request": "launch",
@nascarsayan
nascarsayan / dark_reader.json
Created November 23, 2021 14:38
Dark Reader Settings
{
"enabled": true,
"fetchNews": true,
"theme": {
"mode": 1,
"brightness": 100,
"contrast": 100,
"grayscale": 0,
"sepia": 0,
"useFont": false,
@nascarsayan
nascarsayan / cp_tpl.json
Created July 30, 2021 16:16
VSCode Snippets
{
"CP Template": {
"prefix": "cpt",
"body": [
"#include <bits/stdc++.h>",
"using namespace std;",
"/*----------------------------------------------------------------------------*/",
"#define ff first",
"#define ss second",
"using ll = long long;",
@nascarsayan
nascarsayan / vscode_settings.json
Last active July 30, 2021 15:01
VSCode Settings
{
"editor.fontFamily": "Jetbrains Mono",
"editor.fontLigatures": true,
"editor.tabSize": 2,
"workbench.tree.indent": 4,
"atomKeymap.promptV3Features": true,
"editor.multiCursorModifier": "ctrlCmd",
"workbench.iconTheme": "vscode-icons",
"go.formatTool": "goimports",
"debug.console.fontFamily": "JetBrainsMono NF",
# * Powershell
ubuntu_ver=$(cut -f2 <<< $(lsb_release -r))
# Download the Microsoft repository GPG keys
wget -q "https://packages.microsoft.com/config/ubuntu/${ubuntu_ver}/packages-microsoft-prod.deb"
# Register the Microsoft repository GPG keys
sudo dpkg -i packages-microsoft-prod.deb
@nascarsayan
nascarsayan / functions.ps1
Last active July 16, 2021 07:06
Powershell Functions
$VMMUname = ''
$VMMPass = ''
$Sess = @{}
function Show-VMMMemory {
[alias("vmmspec")]
param()
$hostname = $Sess['vmm'].ComputerName
Write-Output "Getting memory spec details for $hostname ..."
Invoke-Command -Session $Sess['vmm'] {
@nascarsayan
nascarsayan / customStyle.js
Last active March 28, 2021 06:39
Tampermonkey script for customizing the code UI.
// ==UserScript==
// @name Code customizer
// @description Custom css setter : 1. Set monospace font on websites 2. Set tab width
// @namespace local.greasemonkey.codecustomizer
// @include *
// @version 1
// @grant none
// @author nascarsayan@gmail.com
// ==/UserScript==