Skip to content

Instantly share code, notes, and snippets.

View dminkovski's full-sized avatar
👋
Cloud Solution Architect @microsoft

David Minkovski dminkovski

👋
Cloud Solution Architect @microsoft
View GitHub Profile
@dminkovski
dminkovski / copilot-instructions.txt
Created February 12, 2025 22:57
copilot-instructions.txt
# GitHub Copilot Instructions for REST API Development
## General Guidelines:
- Follow modern **TypeScript** best practices.
- Prioritize **modular and reusable code** for maintainability.
- Always use **ESLint** and **Prettier** for code formatting and linting.
- Ensure compatibility with **Node.js LTS versions**.
## API Development:
- Adhere to **RESTful API principles**.
@dminkovski
dminkovski / tools.ts
Created February 7, 2025 11:44
Register llm tools and their implementation function.
import { exec } from 'child_process';
import * as vscode from 'vscode';
export function registerChatTools(context: vscode.ExtensionContext) {
context.subscriptions.push(vscode.lm.registerTool("runScript", new RunInTerminalTool()));
}
interface IRunInTerminalParameters {
command: string;
}
@dminkovski
dminkovski / tools-prompt.tsx
Last active February 7, 2025 11:36
tools-prompt.tsx
// Source: https://github.com/microsoft/vscode-extension-samples/tree/main/chat-sample
import {
AssistantMessage,
BasePromptElementProps,
Chunk,
PrioritizedList,
PromptElement,
PromptElementProps,
PromptMetadata,
@dminkovski
dminkovski / chatparticipant-handler.ts
Last active February 7, 2025 14:34
Creating the Chat Participant Handler
import { renderPrompt } from '@vscode/prompt-tsx';
import * as vscode from 'vscode';
import { ToolCallRound, ToolResultMetadata, ToolUserPrompt } from './tools-prompt';
// define a chat handler
export const handler: vscode.ChatRequestHandler = async (
request: vscode.ChatRequest,
context: vscode.ChatContext,
stream: vscode.ChatResponseStream,
@dminkovski
dminkovski / azlogin.shell
Last active May 17, 2023 15:30
azure-hands-on-container-apps-101
az login
@dminkovski
dminkovski / cypress-plugins-index.js
Last active January 5, 2022 08:15
cypress/plugins/index.js
/// <reference types="cypress" />
// ***********************************************************
// This example plugins/index.js can be used to load plugins
//
// You can change the location of this file or turn off loading
// the plugins file with the 'pluginsFile' configuration option.
//
// You can read more here:
// https://on.cypress.io/plugins-guide
// ***********************************************************
@dminkovski
dminkovski / cypress.json
Created January 3, 2022 14:24
cypress.json
{
"env": {
"TAGS": "not @ignore",
"cypress-plugin-snapshots": {
"autoCleanUp": true,
"autopassNewSnapshots": true,
"diffLines": 3,
"prettier": true,
"imageConfig": {
"createDiffImage": true,