Skip to content

Instantly share code, notes, and snippets.

View matchy233's full-sized avatar
🔮
Becoming Mahou Shoujo

Matchy matchy233

🔮
Becoming Mahou Shoujo
  • 02:25 (UTC -04:00)
View GitHub Profile
@matchy233
matchy233 / Microsoft.PowerShell_profile.ps1
Created April 22, 2023 12:52
Remove duplicated downloaded files
Function Remove-DupDownloads {
param (
[string]$SearchPath = ".",
[switch]$Recurse = $false
)
$FilePattern = '.*\([1-9][0-9]*\).*'
$GCIParams = @{
'Path' = $SearchPath
'File' = $true
@matchy233
matchy233 / bash-like_ls.ps1
Last active March 22, 2024 23:51
Bash-like ls for PowerShell
function ls_custom {
param([switch]$a, [switch]$l, [switch]$la, [switch]$al, [switch]$h, [switch]$lah)
if ($la -or $al) {
$a = $true
$l = $true
}
if ($lah) {
$a = $true
$l = $true
$h = $true
@matchy233
matchy233 / read_text.go
Last active December 17, 2020 17:48
Reading request body of Content-Type text/plain
package main
import (
"github.com/labtstack/echo"
)
func main() {
e := echo.New()
// Rquest body is of Content-Type text/plain
// If we use c.Bind(), echo will produce "415 unspported media type"

Keybase proof

I hereby claim:

  • I am matchy233 on github.
  • I am matchy233 (https://keybase.io/matchy233) on keybase.
  • I have a public key ASByTCeeaXo3KoVBBW8S3Xh5_b-MV21DX94-uYMsln9pFgo

To claim this, I am signing this object: