Skip to content

Instantly share code, notes, and snippets.

View kasuken's full-sized avatar
🦄
Learning how to tame Unicorns

Emanuele Bartolesi kasuken

🦄
Learning how to tame Unicorns
View GitHub Profile
@kasuken
kasuken / epicshit.chatmode.md
Last active July 12, 2025 23:50
Custom Chat Mode for GitHub Copilot and VS Code
description tools model
4.1 Do Epic Shit Mode v1
changes
codebase
editFiles
fetch
new
openSimpleBrowser
problems
runCommands
runTasks
search
searchResults
terminalLastCommand
testFailure
GPT-4.1

You are an autonomous agent tasked with fully resolving the user's query before yielding back control. Follow this workflow strictly and do not end your turn until everything is truly complete.

Rules:

  • Iterate until fully resolved: Never hand control back until the problem is 100% solved, verified, and all steps are checked off.
@kasuken
kasuken / teamsstatusmessages.md
Last active June 26, 2025 07:17
Teams Status Message Templates

🧠 Deep Work / Focus Time

🧘‍♂️ In focus mode — working on something important. Will reply later.

💡 Need me urgently? Tag me or drop an email.

⌛ Heads down in deep work. Will be back online at [insert time].

@kasuken
kasuken / blazor.md
Created May 2, 2025 09:16
Copilot instructions for C#, Blazor and PowerShell

Project coding standards

General C# Coding Standards

  • Use var only when the type is obvious; otherwise, use explicit types.
  • Keep line length under 120 characters.
  • Use consistent indentation and always include braces ({}) even for single-line statements.
  • Group using directives with System.* first, then others in alphabetical order.

Naming Conventions

  • Use PascalCase for component names, classes, methods, and properties.
@kasuken
kasuken / ChangeScreenFrequency.ps1
Created March 11, 2025 20:27
A PowerShell script to change the screen frequency
function Set-ScreenRefreshRate
{
param (
[Parameter(Mandatory=$true)]
[int] $Frequency
)
$pinvokeCode = @"
using System;
using System.Runtime.InteropServices;
@kasuken
kasuken / devcontainer.json
Created November 14, 2023 19:34
GitHub Codespaces devcontainer.json for .NET 8
{
"name": ".NET 8.0",
"image": "mcr.microsoft.com/dotnet/sdk:8.0",
"features": {
"ghcr.io/devcontainers/features/docker-in-docker:2": {},
"ghcr.io/devcontainers/features/github-cli:1": {
"version": "2"
},
"ghcr.io/devcontainers/features/powershell:1": {
"version": "latest"
@kasuken
kasuken / ContactFormModel.cs
Created September 11, 2023 14:32
BlazorContactForm
using System.ComponentModel.DataAnnotations;
namespace BlazorContactForm.Shared
{
public class ContactFormModel
{
[Required(ErrorMessage = "Please enter your name.")]
public string Name { get; set; }
[Required(ErrorMessage = "Please enter your email address.")]
@kasuken
kasuken / devcontainer.json
Created June 9, 2023 12:34
GitHub Codespaces devcontainer.json for Docusaurus
{
"image": "mcr.microsoft.com/vscode/devcontainers/base:ubuntu-20.04",
"settings": {
"[typescript]": {
"editor.defaultFormatter": "esbenp.prettier-vscode",
"editor.formatOnSave": true
},
"[json]": {
"editor.defaultFormatter": "esbenp.prettier-vscode",
"editor.formatOnSave": true
@kasuken
kasuken / Program.cs
Last active December 28, 2022 14:25
Auth0 Device Flow - Console application .NET 7
using Newtonsoft.Json.Linq;
using RestSharp;
const string tenant = "dev-n1b7bzid.us";
const string clientId = "wnvXuZ1rD5VeT4NGBzr1MDNLWu43H5KA";
string access_token = string.Empty;
var client = new RestClient($"https://{tenant}.auth0.com/oauth/device/code");
var request = new RestRequest();
request.Method = Method.Post;
@kasuken
kasuken / component.razor
Created November 21, 2022 12:08
Blazor - write in the console.log with styles
@code {
@inject IJSRuntime JSRuntime
protected override async Task OnInitializedAsync()
{
await JSRuntime.InvokeVoidAsync("console.log", "%cRed Origin 5.0.1 🚀", "color:#0dd8d8; background:#0b1021; font-size:1.5rem; padding:0.15rem 0.25rem; margin: 1rem auto; font-family: Rockwell; border: 2px solid #0dd8d8; border-radius: 4px;font-weight: bold; text-shadow: 1px 1px 1px #00af87bf;");
}
}
@kasuken
kasuken / CleanGitHubRepos.ps1
Last active March 27, 2024 05:53
A script to update your local GitHub repositories with the remote branches (and cleanup)
$branches = ("master", "main", "develop", "dev")
# get all directories in the current directory (just the first level)
$repos = Get-ChildItem -Path . -Filter .git -Recurse -Depth 1 -Force -Directory | Select-Object -expandproperty fullname
function Update-Repos {
Push-Location ".."
$branch = &git rev-parse --abbrev-ref HEAD