summaryrefslogtreecommitdiffstats
path: root/pkg/commands/git_commands/branch_test.go
AgeCommit message (Collapse)Author
2024-05-19Remove redundant variable dedeclarationsJesse Duffield
In go 1.22, loop variables are redeclared with each iteration of the loop, rather than simple updated on each iteration. This means that we no longer need to manually redeclare variables when they're closed over by a function.
2024-03-02Break git.merging.args config into separate arguments on whitespaceStefan Haller
This makes it possible again to pass multiple arguments, for example "--ff-only --autostash". This won't work correctly if you want to use an argument that contains a space, but it's very unlikely that people will want to do that, so I think this is good enough.
2024-03-02Add a test that demonstrates a bug with multiple args in git.merging.args configStefan Haller
We are currently passing the whole string as a single argument, which doesn't work of course.
2023-08-10Allow deleting remote tags/branches from local tag/branch views (#2738)Federico
2023-05-23Construct arg vector manually rather than parse stringJesse Duffield
By constructing an arg vector manually, we no longer need to quote arguments Mandate that args must be passed when building a command Now you need to provide an args array when building a command. There are a handful of places where we need to deal with a string, such as with user-defined custom commands, and for those we now require that at the callsite they use str.ToArgv to do that. I don't want to provide a method out of the box for it because I want to discourage its use. For some reason we were invoking a command through a shell when amending a commit, and I don't believe we needed to do that as there was nothing user- supplied about the command. So I've switched to using a regular command out- side the shell there
2023-05-20Increase test coverageJesse Duffield
2023-01-27fix: fix RefName of detached HEAD to works in ChineseRyooooooga
2022-11-14fix: fix ambiguous branch nameRyooooooga
test: add an integration test for checkout branch by name fix: fix full ref name of detached head refactor: refactor current branch loader chore: use field name explicitly
2022-01-18refactor to group up more commonly used git command stuffJesse Duffield
2022-01-09add some more lintersJesse Duffield
2022-01-09refactorJesse Duffield