Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion claude/settings.json
Original file line number Diff line number Diff line change
@@ -1,8 +1,9 @@
{
"$schema": "https://json.schemastore.org/claude-code-settings.json",
"model": "opus",
"hooks": {},
"enabledPlugins": {
"safety-net@cc-marketplace": true
},
"model": "opus"
"skipDangerousModePermissionPrompt": true
}
44 changes: 43 additions & 1 deletion nushell/init.nu
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,13 @@ def dotenv [
return $record
}

def confirm [
question: string = "Are you sure?"
] {
let answer = (input $"($question) \(y/n\): ")
return ($answer | str downcase | str starts-with "y")
}

def edit-string [
initial: string = ""
] {
Expand Down Expand Up @@ -305,6 +312,16 @@ def getprojectdir [
return ([$nu.home-dir "Documents/dev" $org $repo] | path join)
}

def ghprinfo [] {
let $pr = gh pr view --json number,title,url,state,headRefName,baseRefName,isDraft,reviewDecision,statusCheckRollup | from json
return $pr
}

def ghprexists [] {
let $result = (gh pr view | complete)
return ($result.exit_code == 0)
}

def ghprcheck [
pr
--repo (-r) = ""
Expand Down Expand Up @@ -388,7 +405,7 @@ def gclean [] {
}

def gc [
branch
branch = "mm-update"
] {
let current_branch = (gb)

Expand Down Expand Up @@ -490,6 +507,31 @@ def nuResetConfig [] {
config nu --default | save $nu.config-path -f
}

def gq [] {
let $branch = (gb)

if ($branch == "master") {
gcb
}

gfu

let $prExists = (ghprexists)

if (not $prExists) {
ghaiprq
}

let $continue = (confirm)

if (not $continue) {
return
}

ghprmerge
gclean
}

alias denorun = deno run --no-config --no-lock --node-modules-dir=false -A

alias stodo = deno run --allow-run=rg,git,jq jsr:@michaelmass/stodo/cli search
Expand Down