Skip to content

Where people and agents ship software together. The open-source git platform for the whole job: issues, agents, checks and deploys to the edge.

g1t.sh
867 linesCodeBlameRaw
1---
2title: CLI commands
3description: Every g1t command with its arguments and flags, written from the CLI's own definitions.
4---
5
6<!-- Generated from crates/g1t by `G1T_WRITE_DOCS=1 cargo test -p g1t cli_reference`. Do not edit by hand. -->
7
8Every command of the [g1t CLI](/guides/cli/), with its arguments and flags.
9`g1t <command> --help` prints the same at a terminal. Each command that talks
10to the API names the operations it calls, which link to the
11[API reference](/reference/api/); [`g1t api`](#g1t-api) calls any other.
12
13## Flags every command takes
14
15| Flag | |
16| --- | --- |
17| `-R, --repo <[HOST/]OWNER/NAME>` | The repository, as [HOST/]OWNER/NAME, instead of the current directory's. |
18| `--hostname <HOST>` | The g1t host, such as g1t.sh or git.example.com. |
19| `--json [FIELDS]` | Print JSON: every field, or only the comma-separated FIELDS. |
20| `--jq <EXPRESSION>` | Run a jq expression over the JSON and print what it gives. |
21
22## g1t auth
23
24Sign in, sign out, and set git up to use g1t's credentials.
25
26### g1t auth login
27
28Sign in to a g1t host.
29
30```text
31g1t auth login [OPTIONS]
32```
33
34| Argument or flag | |
35| --- | --- |
36| `--with-token` | Read a token from stdin instead of approving in the browser. |
37| `--insecure-storage` | Keep the token in the config file, not the system keychain. |
38| `--no-browser` | Do not open the browser; just print the link. |
39| `--git` | Also set git up to use g1t's credentials (see `g1t auth setup-git`). |
40
41```text
42Without --with-token, g1t shows a code and a link; approve it in the browser, signed in.
43With --with-token, the token is read from stdin:
44 g1t auth login --with-token < token.txt
45```
46
47Calls [`device_code`](/reference/api/accounts/device-code/), [`device_token`](/reference/api/accounts/device-token/), [`whoami`](/reference/api/accounts/whoami/).
48
49### g1t auth logout
50
51Sign out of an account on a host.
52
53```text
54g1t auth logout [OPTIONS]
55```
56
57| Argument or flag | |
58| --- | --- |
59| `-u, --user <USER>` | The account, when more than one is signed in on the host. |
60
61### g1t auth status
62
63Show which accounts are signed in, and whether their tokens work.
64
65```text
66g1t auth status [OPTIONS]
67```
68
69| Argument or flag | |
70| --- | --- |
71| `--show-token` | Print each token too. |
72
73Calls [`whoami`](/reference/api/accounts/whoami/).
74
75### g1t auth token
76
77Print the token in use, for another program.
78
79```text
80g1t auth token [OPTIONS]
81```
82
83| Argument or flag | |
84| --- | --- |
85| `-u, --user <USER>` | The account, when more than one is signed in on the host. |
86
87### g1t auth switch
88
89Make another signed-in account on a host the active one.
90
91```text
92g1t auth switch [OPTIONS]
93```
94
95| Argument or flag | |
96| --- | --- |
97| `-u, --user <USER>` | The account, when more than one is signed in on the host. |
98
99### g1t auth setup-git
100
101Make git use g1t's credentials for pushing and fetching over HTTPS.
102
103```text
104g1t auth setup-git [OPTIONS]
105```
106
107| Argument or flag | |
108| --- | --- |
109| `--dry-run` | Print the git config commands instead of running them. |
110
111## g1t repo
112
113Repositories: view, clone, create, list.
114
115### g1t repo view
116
117Show a repository.
118
119```text
120g1t repo view [OPTIONS] [REPOSITORY]
121```
122
123| Argument or flag | |
124| --- | --- |
125| `[REPOSITORY]` | OWNER/NAME; the current repository when left out. |
126| `-w, --web` | Open it in the browser. |
127
128Calls [`get_repo`](/reference/api/repositories/get-repo/).
129
130### g1t repo clone
131
132Clone a repository.
133
134```text
135g1t repo clone [OPTIONS] <REPOSITORY> [DIRECTORY] [-- <GIT_FLAGS>...]
136```
137
138| Argument or flag | |
139| --- | --- |
140| `<REPOSITORY>` | OWNER/NAME, or NAME for one of your own. |
141| `[DIRECTORY]` | Where to clone it. |
142| `[GIT_FLAGS]` | After `--`. Flags for git clone, after --. |
143
144Calls [`whoami`](/reference/api/accounts/whoami/).
145
146### g1t repo create
147
148Make a repository.
149
150```text
151g1t repo create [OPTIONS] [NAME]
152```
153
154| Argument or flag | |
155| --- | --- |
156| `[NAME]` | NAME, or WORKSPACE/NAME. |
157| `--public` | Anyone can see it. Repositories are private unless this is given. |
158| `--private` | Only people with a role on it can see it (the default). |
159| `-d, --description <DESCRIPTION>` | |
160| `-c, --clone` | Clone it once it is made. |
161| `--source <DIR>` | Add it as a remote of this directory's repository and push it there. |
162| `--remote <REMOTE>` | The remote's name, with --source. Default: `origin`. |
163
164Calls [`create_repo`](/reference/api/repositories/create-repo/).
165
166### g1t repo list
167
168List repositories you can see.
169
170```text
171g1t repo list [OPTIONS] [WORKSPACE]
172```
173
174| Argument or flag | |
175| --- | --- |
176| `[WORKSPACE]` | Only this workspace's. |
177| `-q, --query <QUERY>` | Only those whose name or description holds this. |
178| `-L, --limit <LIMIT>` | Default: `20`. |
179
180Calls [`list_repos`](/reference/api/repositories/list-repos/).
181
182## g1t issue
183
184Issues: list, view, create, comment, close, reopen, edit.
185
186### g1t issue list
187
188List issues.
189
190```text
191g1t issue list [OPTIONS]
192```
193
194| Argument or flag | |
195| --- | --- |
196| `-s, --state <STATE>` | One of `open`, `closed`, `all`. Default: `open`. |
197| `-l, --label <LABEL>` | Only issues with this label. |
198| `-m, --milestone <MILESTONE>` | Only issues in the milestone of this number. |
199| `-a, --assignee <ASSIGNEE>` | Only issues assigned to this person (@me for you). |
200| `-A, --author <AUTHOR>` | Only issues opened by this person (@me for you). |
201| `-L, --limit <LIMIT>` | Default: `20`. |
202
203Calls [`list_issues`](/reference/api/issues/list-issues/).
204
205### g1t issue view
206
207Show an issue, with its comments.
208
209```text
210g1t issue view [OPTIONS] <NUMBER>
211```
212
213| Argument or flag | |
214| --- | --- |
215| `<NUMBER>` | The issue's number. |
216| `-c, --comments` | Show its comments too. |
217| `-w, --web` | Open it in the browser. |
218
219Calls [`get_issue`](/reference/api/issues/get-issue/).
220
221### g1t issue create
222
223Open an issue.
224
225```text
226g1t issue create [OPTIONS]
227```
228
229| Argument or flag | |
230| --- | --- |
231| `-t, --title <TITLE>` | |
232| `-b, --body <BODY>` | The text. Markdown. |
233| `-F, --body-file <FILE>` | Read the text from a file, or - for stdin. |
234| `-l, --label <LABEL>` | A label; repeat for more. |
235| `-a, --assignee <ASSIGNEE>` | Someone to assign; repeat for more (@me for you). |
236| `-m, --milestone <MILESTONE>` | A milestone's number. |
237| `-w, --web` | Open the new-issue page in the browser instead. |
238
239Calls [`create_issue`](/reference/api/issues/create-issue/), [`update_issue`](/reference/api/issues/update-issue/).
240
241### g1t issue comment
242
243Comment on an issue.
244
245```text
246g1t issue comment [OPTIONS] [NUMBER]
247```
248
249| Argument or flag | |
250| --- | --- |
251| `[NUMBER]` | The number; for a pull request, the current branch's when left out. |
252| `-b, --body <BODY>` | The text. Markdown. |
253| `-F, --body-file <FILE>` | Read the text from a file, or - for stdin. |
254
255Calls [`add_comment`](/reference/api/issues/add-comment/).
256
257### g1t issue close
258
259Close an issue.
260
261```text
262g1t issue close [OPTIONS] <NUMBER>
263```
264
265| Argument or flag | |
266| --- | --- |
267| `<NUMBER>` | |
268| `-r, --reason <REASON>` | One of `completed`, `not-planned`. |
269| `-c, --comment <COMMENT>` | Leave a comment as it closes. |
270
271Calls [`close_issue`](/reference/api/issues/close-issue/), [`add_comment`](/reference/api/issues/add-comment/).
272
273### g1t issue reopen
274
275Reopen an issue.
276
277```text
278g1t issue reopen [OPTIONS] <NUMBER>
279```
280
281| Argument or flag | |
282| --- | --- |
283| `<NUMBER>` | |
284| `-c, --comment <COMMENT>` | Leave a comment as it reopens. |
285
286Calls [`reopen_issue`](/reference/api/issues/reopen-issue/), [`add_comment`](/reference/api/issues/add-comment/).
287
288### g1t issue edit
289
290Change an issue's title, body, labels, assignees or milestone.
291
292```text
293g1t issue edit [OPTIONS] <NUMBER>
294```
295
296| Argument or flag | |
297| --- | --- |
298| `<NUMBER>` | |
299| `-t, --title <TITLE>` | |
300| `-b, --body <BODY>` | The text. Markdown. |
301| `-F, --body-file <FILE>` | Read the text from a file, or - for stdin. |
302| `--add-label <LABEL>` | |
303| `--remove-label <LABEL>` | |
304| `--add-assignee <LOGIN>` | |
305| `--remove-assignee <LOGIN>` | |
306| `-m, --milestone <MILESTONE>` | A milestone's number. |
307| `--remove-milestone` | Take it out of its milestone. |
308
309Calls [`update_issue`](/reference/api/issues/update-issue/), [`get_issue`](/reference/api/issues/get-issue/).
310
311## g1t pr
312
313Pull requests: list, view, create, check out, diff, checks, review, merge.
314
315### g1t pr list
316
317List pull requests.
318
319```text
320g1t pr list [OPTIONS]
321```
322
323| Argument or flag | |
324| --- | --- |
325| `-s, --state <STATE>` | One of `open`, `closed`, `merged`, `all`. Default: `open`. |
326| `-B, --base <BASE>` | Only those merging into this branch. |
327| `-l, --label <LABEL>` | |
328| `-A, --author <AUTHOR>` | Only those opened by this person (@me for you). |
329| `-d, --draft` | Only drafts. |
330| `-L, --limit <LIMIT>` | Default: `20`. |
331
332Calls [`list_pull_requests`](/reference/api/pull-requests/list-pull-requests/).
333
334### g1t pr view
335
336Show a pull request.
337
338```text
339g1t pr view [OPTIONS] [NUMBER]
340```
341
342| Argument or flag | |
343| --- | --- |
344| `[NUMBER]` | The number; the current branch's when left out. |
345| `-c, --comments` | |
346| `-w, --web` | |
347
348Calls [`get_pull_request`](/reference/api/pull-requests/get-pull-request/), [`list_pull_requests`](/reference/api/pull-requests/list-pull-requests/).
349
350### g1t pr create
351
352Open a pull request from a branch, or start one for an issue.
353
354```text
355g1t pr create [OPTIONS]
356```
357
358| Argument or flag | |
359| --- | --- |
360| `-t, --title <TITLE>` | |
361| `-b, --body <BODY>` | The text. Markdown. |
362| `-F, --body-file <FILE>` | Read the text from a file, or - for stdin. |
363| `-B, --base <BASE>` | The branch to merge into; the default branch when left out. |
364| `-H, --head <HEAD>` | The branch with the changes; the current one when left out. |
365| `-i, --issue <ISSUE>` | The issue it is for. Without a branch, starts a draft in a working copy of its own. |
366| `-f, --fill` | Take the title and body from the branch's commits. |
367| `-d, --draft` | Open it as a draft. |
368| `--no-push` | Do not push the branch first. |
369
370Calls [`create_pull_request`](/reference/api/pull-requests/create-pull-request/), [`get_repo`](/reference/api/repositories/get-repo/), [`convert_pull_request_to_draft`](/reference/api/pull-requests/convert-pull-request-to-draft/).
371
372### g1t pr checkout
373
374Check a pull request's changes out locally.
375
376```text
377g1t pr checkout [OPTIONS] <NUMBER>
378```
379
380| Argument or flag | |
381| --- | --- |
382| `<NUMBER>` | |
383| `-b, --branch <BRANCH>` | The local branch's name; pr-NUMBER when left out. |
384| `-f, --force` | Reset the local branch to the pull request's head even if it has other commits. |
385
386Calls [`get_pull_request`](/reference/api/pull-requests/get-pull-request/).
387
388### g1t pr diff
389
390Show a pull request's changes as a diff.
391
392```text
393g1t pr diff [OPTIONS] [NUMBER]
394```
395
396| Argument or flag | |
397| --- | --- |
398| `[NUMBER]` | |
399| `--name-only` | Only the changed files' names. |
400| `--color <COLOR>` | Color: auto, always or never. Default: `auto`. |
401
402Calls [`get_pull_request_changes`](/reference/api/pull-requests/get-pull-request-changes/).
403
404### g1t pr checks
405
406Show a pull request's checks; --watch waits for them.
407
408```text
409g1t pr checks [OPTIONS] [NUMBER]
410```
411
412| Argument or flag | |
413| --- | --- |
414| `[NUMBER]` | |
415| `-w, --watch` | Wait until every check has finished. |
416| `--fail-fast` | With --watch, stop at the first failing check. |
417| `-i, --interval <INTERVAL>` | Seconds between looks, with --watch. Default: `10`. |
418
419Calls [`get_pull_request`](/reference/api/pull-requests/get-pull-request/), [`list_check_runs_for_ref`](/reference/api/checks/list-check-runs-for-ref/), [`get_combined_status`](/reference/api/checks/get-combined-status/).
420
421### g1t pr review
422
423Approve a pull request, or ask for changes.
424
425```text
426g1t pr review [OPTIONS] <--approve|--request-changes|--comment> [NUMBER]
427```
428
429| Argument or flag | |
430| --- | --- |
431| `[NUMBER]` | |
432| `-a, --approve` | |
433| `-r, --request-changes` | |
434| `-c, --comment` | Comment without approving or asking for changes. |
435| `-b, --body <BODY>` | The text. Markdown. |
436| `-F, --body-file <FILE>` | Read the text from a file, or - for stdin. |
437
438Calls [`review_pull_request`](/reference/api/pull-requests/review-pull-request/), [`add_comment`](/reference/api/issues/add-comment/).
439
440### g1t pr merge
441
442Merge a pull request.
443
444```text
445g1t pr merge [OPTIONS] [NUMBER]
446```
447
448| Argument or flag | |
449| --- | --- |
450| `[NUMBER]` | |
451| `--keep-issue-open` | Leave the issue it is for open. |
452| `--admin` | Merge past failing required checks and rules (needs the Admin role). |
453| `-d, --delete-branch` | Delete the local and remote branch afterwards. |
454
455Calls [`merge_pull_request`](/reference/api/pull-requests/merge-pull-request/), [`delete_branch`](/reference/api/repositories/delete-branch/).
456
457### g1t pr ready
458
459Mark a draft ready for review, or turn it back into a draft.
460
461```text
462g1t pr ready [OPTIONS] [NUMBER]
463```
464
465| Argument or flag | |
466| --- | --- |
467| `[NUMBER]` | |
468| `-s, --summary <SUMMARY>` | What changed and why; it becomes the description. The current one when left out. |
469| `--undo` | Turn it back into a draft. |
470
471Calls [`mark_pull_request_ready`](/reference/api/pull-requests/mark-pull-request-ready/), [`convert_pull_request_to_draft`](/reference/api/pull-requests/convert-pull-request-to-draft/).
472
473### g1t pr comment
474
475Comment on a pull request.
476
477```text
478g1t pr comment [OPTIONS] [NUMBER]
479```
480
481| Argument or flag | |
482| --- | --- |
483| `[NUMBER]` | The number; for a pull request, the current branch's when left out. |
484| `-b, --body <BODY>` | The text. Markdown. |
485| `-F, --body-file <FILE>` | Read the text from a file, or - for stdin. |
486
487Calls [`add_comment`](/reference/api/issues/add-comment/).
488
489### g1t pr close
490
491Close a pull request without merging it.
492
493```text
494g1t pr close [OPTIONS] [NUMBER]
495```
496
497| Argument or flag | |
498| --- | --- |
499| `[NUMBER]` | The number; the current branch's when left out. |
500
501Calls [`close_pull_request`](/reference/api/pull-requests/close-pull-request/).
502
503### g1t pr reopen
504
505Reopen a closed pull request.
506
507```text
508g1t pr reopen [OPTIONS] [NUMBER]
509```
510
511| Argument or flag | |
512| --- | --- |
513| `[NUMBER]` | The number; the current branch's when left out. |
514
515Calls [`reopen_pull_request`](/reference/api/pull-requests/reopen-pull-request/).
516
517## g1t run
518
519Workflow runs: list, view, watch, logs, rerun, cancel.
520
521### g1t run list
522
523List workflow runs, newest first.
524
525```text
526g1t run list [OPTIONS]
527```
528
529| Argument or flag | |
530| --- | --- |
531| `-w, --workflow <WORKFLOW>` | Only this workflow's: its file name or id. |
532| `-b, --branch <BRANCH>` | |
533| `-e, --event <EVENT>` | Only runs for this event: push, pull_request, schedule... |
534| `-c, --commit <COMMIT>` | Only runs of this commit. |
535| `--pr <PR>` | Only runs for this pull request. |
536| `-L, --limit <LIMIT>` | Default: `20`. |
537
538Calls [`list_workflow_runs`](/reference/api/actions/list-workflow-runs/).
539
540### g1t run view
541
542Show a run's jobs and steps.
543
544```text
545g1t run view [OPTIONS] [RUN]
546```
547
548| Argument or flag | |
549| --- | --- |
550| `[RUN]` | |
551| `-j, --job <JOB>` | Show this job's steps only. |
552| `--log` | Print the log too. |
553| `--log-failed` | Print the failing steps' logs too. |
554| `-w, --web` | |
555| `--exit-status` | Exit 1 when the run failed. |
556
557Calls [`get_workflow_run`](/reference/api/actions/get-workflow-run/), [`get_job_logs`](/reference/api/actions/get-job-logs/).
558
559### g1t run watch
560
561Follow a run until it finishes; exits 1 if it fails.
562
563```text
564g1t run watch [OPTIONS] [RUN]
565```
566
567| Argument or flag | |
568| --- | --- |
569| `[RUN]` | |
570| `-i, --interval <INTERVAL>` | Seconds between looks. Default: `3`. |
571
572Calls [`get_workflow_run`](/reference/api/actions/get-workflow-run/).
573
574### g1t run logs
575
576Print a run's logs; --failed prints only the failing steps' tails.
577
578```text
579g1t run logs [OPTIONS] [RUN]
580```
581
582| Argument or flag | |
583| --- | --- |
584| `[RUN]` | |
585| `-j, --job <JOB>` | Only this job's (its id, key or name). |
586| `-f, --failed` | Only the failing steps, and only their last lines. |
587| `-n, --tail <TAIL>` | How many lines of each failing step to print, with --failed. Default: `60`. |
588
589Calls [`get_workflow_run`](/reference/api/actions/get-workflow-run/), [`get_job_logs`](/reference/api/actions/get-job-logs/).
590
591### g1t run rerun
592
593Run a run again: all of it, its failed jobs, or one job.
594
595```text
596g1t run rerun [OPTIONS] [RUN]
597```
598
599| Argument or flag | |
600| --- | --- |
601| `[RUN]` | |
602| `--failed` | Only the jobs that failed. |
603| `-j, --job <JOB>` | Only this job (its id). |
604| `-d, --debug` | With debug logging. |
605
606Calls [`rerun_workflow_run`](/reference/api/actions/rerun-workflow-run/), [`rerun_failed_jobs`](/reference/api/actions/rerun-failed-jobs/), [`rerun_job`](/reference/api/actions/rerun-job/).
607
608### g1t run cancel
609
610Cancel a run.
611
612```text
613g1t run cancel [OPTIONS] [RUN]
614```
615
616| Argument or flag | |
617| --- | --- |
618| `[RUN]` | The run's id (run_…) or number; the current branch's latest when left out. |
619
620Calls [`cancel_workflow_run`](/reference/api/actions/cancel-workflow-run/).
621
622## g1t secret
623
624Secrets for workflows and deployments, a repository's or a workspace's.
625
626### g1t secret list
627
628List secrets' names (never their values).
629
630```text
631g1t secret list [OPTIONS]
632```
633
634| Argument or flag | |
635| --- | --- |
636| `-w, --workspace <WORKSPACE>` | A workspace's secrets instead of the repository's. |
637| `-e, --env <ENVIRONMENT>` | Only the value for this environment (production, preview...). |
638
639Calls [`list_actions_secrets`](/reference/api/secrets-and-variables/list-actions-secrets/), [`list_actions_secrets_for_workspace`](/reference/api/secrets-and-variables/list-actions-secrets-for-workspace/).
640
641### g1t secret set
642
643Set a secret. The value is read from stdin when not given.
644
645```text
646g1t secret set [OPTIONS] <NAME>
647```
648
649| Argument or flag | |
650| --- | --- |
651| `<NAME>` | The secret's name; uppercased. |
652| `-b, --body <BODY>` | The value. Read from stdin when left out, so it stays out of your shell's history. |
653| `-w, --workspace <WORKSPACE>` | A workspace's secrets instead of the repository's. |
654| `-e, --env <ENVIRONMENT>` | Only the value for this environment (production, preview...). |
655| `--available-to <WHO>` | Who can read it: workflows, deployments, or both (repeat). |
656| `--brokered-host <HOST>` | Broker it: jobs get a stand-in, and g1t fills the value in only on requests to this host. Repeat for more. |
657| `--note <NOTE>` | A note for whoever reads the list. |
658
659Calls [`set_actions_secret`](/reference/api/secrets-and-variables/set-actions-secret/), [`set_actions_secret_for_workspace`](/reference/api/secrets-and-variables/set-actions-secret-for-workspace/).
660
661### g1t secret delete
662
663Delete a secret.
664
665```text
666g1t secret delete [OPTIONS] <NAME>
667```
668
669| Argument or flag | |
670| --- | --- |
671| `<NAME>` | |
672| `-w, --workspace <WORKSPACE>` | A workspace's secrets instead of the repository's. |
673| `-e, --env <ENVIRONMENT>` | Only the value for this environment (production, preview...). |
674
675Calls [`delete_actions_secret`](/reference/api/secrets-and-variables/delete-actions-secret/), [`delete_actions_secret_for_workspace`](/reference/api/secrets-and-variables/delete-actions-secret-for-workspace/).
676
677## g1t deploy
678
679Deployments: list and view.
680
681### g1t deploy list
682
683List deployments, newest first.
684
685```text
686g1t deploy list [OPTIONS]
687```
688
689| Argument or flag | |
690| --- | --- |
691| `-e, --env <ENV>` | |
692| `-s, --state <STATE>` | queued, in_progress, success, failure, error or inactive. |
693| `--source <SOURCE>` | api, actions or g1t_page. |
694| `-L, --limit <LIMIT>` | Default: `20`. |
695
696Calls [`list_deployments`](/reference/api/deployments/list-deployments/).
697
698### g1t deploy view
699
700Show a deployment and its statuses.
701
702```text
703g1t deploy view [OPTIONS] <ID>
704```
705
706| Argument or flag | |
707| --- | --- |
708| `<ID>` | |
709| `-w, --web` | |
710
711Calls [`get_deployment`](/reference/api/deployments/get-deployment/).
712
713## g1t logs
714
715A project's logs and errors.
716
717```text
718g1t logs [OPTIONS]
719```
720
721| Argument or flag | |
722| --- | --- |
723| `-p, --project <PROJECT>` | The project; the current repository's when left out. |
724| `--errors` | Grouped errors instead of log lines. |
725| `-q, --query <QUERY>` | Lines holding all of these words, or a "quoted phrase". |
726| `-l, --level <LEVEL>` | Levels: trace, debug, info, warn, error, fatal (comma-separated). |
727| `-e, --env <ENV>` | |
728| `--service <SERVICE>` | |
729| `-s, --since <SINCE>` | How far back: 15m, 2h, 1d, or a time like 2026-10-12T09:00:00Z. |
730| `--state <STATE>` | With --errors: open, resolved or ignored. |
731| `-f, --follow` | Keep printing new lines as they come. |
732| `-L, --limit <LIMIT>` | Default: `50`. |
733
734Calls [`list_logs`](/reference/api/observability/list-logs/), [`list_errors`](/reference/api/observability/list-errors/), [`list_projects`](/reference/api/projects/list-projects/), [`get_repo`](/reference/api/repositories/get-repo/).
735
736## g1t status
737
738What needs you: your pull requests, reviews asked of you, your issues, failing checks.
739
740```text
741g1t status [OPTIONS]
742```
743
744Calls [`search`](/reference/api/search/search/), [`list_notifications`](/reference/api/notifications/list-notifications/), [`get_pull_request`](/reference/api/pull-requests/get-pull-request/).
745
746## g1t api
747
748Call any API operation or path, with your token.
749
750```text
751g1t api [OPTIONS] [ENDPOINT]
752```
753
754| Argument or flag | |
755| --- | --- |
756| `[ENDPOINT]` | An operation's name, or a path. |
757| `--list [QUERY]` | List the operations, or those matching this word. |
758| `-X, --method <METHOD>` | The HTTP method: GET unless fields are given, then POST. |
759| `-f, --raw-field <KEY=VALUE>` | A string field, key=value. key[]=value adds to a list. |
760| `-F, --field <KEY=VALUE>` | A typed field: true, false, null and numbers become JSON; @file reads a file. |
761| `-H, --header <KEY:VALUE>` | A request header, key:value. |
762| `--input <FILE>` | The request body, from a file or - for stdin. |
763| `--paginate` | Follow next pages until there are none. |
764| `--slurp` | With --paginate, put every page's items into one array. |
765| `-i, --include` | Print the status line and headers too. |
766| `--silent` | Print nothing on success. |
767
768```text
769ENDPOINT is an operation's name (list_issues) or a path (/repos/{owner}/{name}/issues).
770{owner}, {name}, {repo} and {workspace} are filled in from the current repository,
771and an operation's other path parameters from -f/-F fields of the same name.
772
773Examples:
774 g1t api list_issues -f state=closed
775 g1t api /user --jq .username
776 g1t api create_issue -f title='Broken link' -f labels[]=docs
777 g1t api list_workflow_runs --paginate --jq '.[].conclusion'
778 g1t api --list issue
779```
780
781## g1t browse
782
783Open the repository, an issue or a pull request in the browser.
784
785```text
786g1t browse [OPTIONS] [TARGET]
787```
788
789| Argument or flag | |
790| --- | --- |
791| `[TARGET]` | An issue or pull request number, a file path (path:line), or a commit. |
792| `-b, --branch <BRANCH>` | The branch to show files on. |
793| `-s, --settings` | |
794| `--issues` | |
795| `--pulls` | |
796| `--actions` | |
797| `-n, --no-browser` | Print the address instead of opening it. |
798
799## g1t alias
800
801Shortcuts for commands you type often.
802
803### g1t alias set
804
805Make an alias: g1t alias set co 'pr checkout'. Start it with ! to run it through the shell.
806
807```text
808g1t alias set [OPTIONS] <NAME> <EXPANSION>
809```
810
811| Argument or flag | |
812| --- | --- |
813| `<NAME>` | |
814| `<EXPANSION>` | What it expands to. $1, $2... take the arguments after it. |
815
816### g1t alias list
817
818List aliases.
819
820```text
821g1t alias list [OPTIONS]
822```
823
824### g1t alias delete
825
826Delete an alias.
827
828```text
829g1t alias delete [OPTIONS] <NAME>
830```
831
832| Argument or flag | |
833| --- | --- |
834| `<NAME>` | |
835
836## g1t completion
837
838Print a shell completion script.
839
840```text
841g1t completion [OPTIONS] <SHELL>
842```
843
844| Argument or flag | |
845| --- | --- |
846| `<SHELL>` | One of `bash`, `elvish`, `fish`, `powershell`, `zsh`. |
847
848## g1t push
849
850Push a local container image to g1t's registry, in chunks.
851
852```text
853g1t push [OPTIONS] [IMAGE]
854```
855
856| Argument or flag | |
857| --- | --- |
858| `[IMAGE]` | The local image, [REGISTRY/]NAME[:TAG]. |
859| `--as <ADDRESS>` | Where to push, when the image's own name is not an address on g1t.sh. The tag defaults to latest. |
860| `--chunk-size <SIZE>` | How much of a layer each request carries: 5MB to 95MB. Default: `90MB`. |
861| `--token-stdin` | Read the g1t token from stdin. |
862| `--archive <FILE>` | Push a tarball `docker save` wrote, instead of asking docker for the image. |
863
864```text
865The token is the first of: --token-stdin, G1T_TOKEN, the account `g1t auth login`
866signed in for the registry's host, or what `docker login g1t.sh` stored.
867```