On 2/5/23 22:37, Miller Puckette via Pd-dev wrote:
Yep, I originally made a "0.53" branch but then messed it up so badly
I had to start over - and thought it better to change the name to
avoid confusion.

i see.
it seems like the "avoid confusion" did not utterly succeed though ;-)

in any case: while it is possible to have branches and tags use the same name, i think this is really going to be super-confusing, and should therefore be avoided.

e.g., i expect the 0.53-2 release to carry the "0.53-2" tag (just like the other releases), but it is somewhat unclear what i get when doing a "git checkout 0.53-2" (see PS).

i would therefore recommend to use some "namespace" for maintenance branches, e.g. "maintenance/0.53".

alternatively (and i like this better), is to just revert to your original name "<major>.<minor>" without the bugfix number (that is "0.53"). since Pd releases always have a bugfix number ("0.53-0") this shouldn't collide in practice.

as for "messing up beyond repair": in this case i would just fix the problems locally (abandoning the broken branch; starting anew with the nice name) and force-push and be done with it. (in general "force-pushing" is frowned upon, but it's there for a purpose, and i think this purpose is to fix messed up things)

mgfadsr
IOhannes


PS: checking out with tags and branches...


usually, to checkout a release, you (well: I) do something like this:

```
$ git checkout 0.53-1
Note: switching to '0.53-1'.
[...]
HEAD is now at b2dcb6ce [...]
```

and when switching between branches:
```
$ git checkout 0.53
branch '0.53' set up to track 'origin/0.53'.
Switched to a new branch '0.53'
```

but if there's both a branch and a tag with the same name, i get:

```
$ git checkout 0.53-2
warning: refname '0.53-2' is ambiguous.
Switched to branch '0.53-2'
Your branch is up to date with 'origin/0.53-2'.
```

*or*

```
$ git checkout 0.53-2
Note: switching to '0.53-2'.
[...]
HEAD is now at 12345678 [...]
```

the last example gets me the "0.53-2" tag, whereas the former example gives me the "0.53-2" branch.
what i get depends on whether i have already a local branch.
so a 'git checkout FOO' gives you:
1. the local branch 'FOO'
2. if that doesn't exist, the tag 'FOO'
3. if that doesn't exist, the remove branch 'FOO'

Attachment: OpenPGP_signature
Description: OpenPGP digital signature

_______________________________________________
Pd-dev mailing list
[email protected]
https://lists.puredata.info/listinfo/pd-dev

Reply via email to