Commit f4f4f79
committed
Fix Copybara ls-remote branch parsing for special characters
Update regexes in GitRepository.java to support branch names with special characters (using \S+ instead of \w+). Previously, branch names containing hyphens (e.g., `feature-branch`), dots (e.g., `v1.0.0`), slashes (e.g., `feature/foo`), or emojis (e.g., `branch-🚀`) failed to be handled.
BUG: 523347052
GWSQ_IGNORES: chriscampos@google.com
PiperOrigin-RevId: 931333663
Change-Id: I6bcd4aa04fad48b57433604120d232b2af25ed081 parent ffac707 commit f4f4f79
2 files changed
Lines changed: 12 additions & 4 deletions
File tree
- javatests/com/google/copybara/git
- java/com/google/copybara/git
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
108 | 108 | | |
109 | 109 | | |
110 | 110 | | |
111 | | - | |
| 111 | + | |
112 | 112 | | |
113 | 113 | | |
114 | 114 | | |
115 | 115 | | |
116 | | - | |
117 | | - | |
118 | | - | |
| 116 | + | |
119 | 117 | | |
120 | 118 | | |
121 | 119 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1946 | 1946 | | |
1947 | 1947 | | |
1948 | 1948 | | |
| 1949 | + | |
| 1950 | + | |
| 1951 | + | |
| 1952 | + | |
| 1953 | + | |
| 1954 | + | |
| 1955 | + | |
| 1956 | + | |
| 1957 | + | |
| 1958 | + | |
1949 | 1959 | | |
1950 | 1960 | | |
1951 | 1961 | | |
| |||
0 commit comments