Skip to content

Instantly share code, notes, and snippets.

View kawishbit's full-sized avatar
😶
Brace Yourself

KawishBit kawishbit

😶
Brace Yourself
View GitHub Profile
@kawishbit
kawishbit / deleteLocalBranch.ps1
Created May 8, 2024 06:18
Delete Local Branches Using Powershell
# Array of branch names that you want to include
$excludeBranches = @("main", "develop", "feature1", "hotfix1")
# Retrieve all local branches using git command
$allBranches = git branch --format="%(refname:short)"
# Convert the output into an array
$allBranchesArray = $allBranches -split "`n"
# Filter the branches based on whether they are in the specified array
@kawishbit
kawishbit / convertJmeterXmlToCsv.py
Last active November 13, 2023 16:02
Convert XML Result to CSV Result for Jmeter using Python
#!/usr/bin/env python
# 2023 version of https://gist.github.com/tomdottom/b017244a221f8076c4b0adc6feeeb921
# I added 3 new fields (sentBytes, URL, Connect) and used etree instead
import csv
import sys
from pprint import pprint
import xml.etree.ElementTree as ET