| 272 | } |
| 273 | |
| 274 | void detach_advice(const char *new_name) |
| 275 | { |
| 276 | const char *fmt = |
| 277 | _("Note: switching to '%s'.\n" |
| 278 | "\n" |
| 279 | "You are in 'detached HEAD' state. You can look around, make experimental\n" |
| 280 | "changes and commit them, and you can discard any commits you make in this\n" |
| 281 | "state without impacting any branches by switching back to a branch.\n" |
| 282 | "\n" |
| 283 | "If you want to create a new branch to retain commits you create, you may\n" |
| 284 | "do so (now or later) by using -c with the switch command. Example:\n" |
| 285 | "\n" |
| 286 | " git switch -c <new-branch-name>\n" |
| 287 | "\n" |
| 288 | "Or undo this operation with:\n" |
| 289 | "\n" |
| 290 | " git switch -\n" |
| 291 | "\n" |
| 292 | "Turn off this advice by setting config variable advice.detachedHead to false\n\n"); |
| 293 | |
| 294 | fprintf(stderr, fmt, new_name); |
| 295 | } |
| 296 | |
| 297 | void advise_on_moving_dirty_path(struct string_list *pathspec_list) |
| 298 | { |
no outgoing calls
no test coverage detected