@loongphy/codex-auth-linux-x64 0.1.4-rc.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/LICENSE ADDED
@@ -0,0 +1,21 @@
1
+ MIT License
2
+
3
+ Copyright (c) 2026-PRESENT Loongphy<https://github.com/loongphy>
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ of this software and associated documentation files (the "Software"), to deal
7
+ in the Software without restriction, including without limitation the rights
8
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ copies of the Software, and to permit persons to whom the Software is
10
+ furnished to do so, subject to the following conditions:
11
+
12
+ The above copyright notice and this permission notice shall be included in all
13
+ copies or substantial portions of the Software.
14
+
15
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21
+ SOFTWARE.
package/README.md ADDED
@@ -0,0 +1,103 @@
1
+ # Codex Auth
2
+
3
+ ![command list](https://github.com/user-attachments/assets/7bbd463b-c5ed-4b90-b1f6-8dfbf21a8944)
4
+
5
+ `codex-auth` is a local-only command-line tool for switching Codex accounts.
6
+
7
+ - It never calls OpenAI APIs; all operations happen locally on your machine.
8
+ - It reads and updates local Codex files under `~/.codex` (including `sessions/` and auth files).
9
+
10
+ ## Install
11
+
12
+ - npm:
13
+
14
+ ```shell
15
+ npm install -g @loongphy/codex-auth
16
+ ```
17
+
18
+ You can also run it without a global install:
19
+
20
+ ```shell
21
+ npx @loongphy/codex-auth list
22
+ ```
23
+
24
+ The npm package uses npm's platform-aware install model: the root package depends on platform packages via `optionalDependencies`, and npm installs the matching binary package for your current OS/CPU.
25
+ Supported npm targets: Linux x64, macOS ARM64, Windows x64.
26
+ Tag publishing uses npm Trusted Publishing via GitHub Actions OIDC from `.github/workflows/release.yml`.
27
+
28
+ - Linux/macOS/WSL2:
29
+
30
+ ```shell
31
+ curl -fsSL https://raw.githubusercontent.com/loongphy/codex-auth/main/scripts/install.sh | bash
32
+ ```
33
+
34
+ The installer writes the install dir to your shell profile by default.
35
+ Supported profiles: `~/.bashrc`/`~/.bash_profile`/`~/.profile`, `~/.zshrc`/`~/.zprofile`, `~/.config/fish/config.fish`.
36
+ Use `--no-add-to-path` to skip profile updates.
37
+
38
+ - Windows (PowerShell):
39
+
40
+ ```powershell
41
+ irm https://raw.githubusercontent.com/loongphy/codex-auth/main/scripts/install.ps1 | iex
42
+ ```
43
+
44
+ The installer adds the install dir to current/user `PATH` by default.
45
+ Use `-NoAddToPath` to skip user `PATH` persistence.
46
+
47
+ ## Full Commands
48
+
49
+ ```shell
50
+ codex-auth list # list all accounts
51
+ codex-auth add [--no-login] # add current account (runs `codex login` by default)
52
+ codex-auth switch [<email>] # switch active account (interactive or partial/fragment match)
53
+ codex-auth import <path> [--alias <alias>] # smart import: file -> single import, folder -> batch import
54
+ codex-auth remove # remove accounts (interactive multi-select)
55
+ ```
56
+
57
+ ### Examples
58
+
59
+ List accounts (default table with borders):
60
+
61
+ ```shell
62
+ codex-auth list
63
+ ```
64
+
65
+ Add the currently logged-in Codex account:
66
+
67
+ ```shell
68
+ codex-auth add
69
+ ```
70
+
71
+ Import an auth.json backup:
72
+
73
+ ```shell
74
+ codex-auth import /path/to/auth.json --alias personal
75
+ ```
76
+
77
+ Batch import from a folder:
78
+
79
+ ```shell
80
+ codex-auth import /path/to/auth-exports
81
+ ```
82
+
83
+ Switch accounts (interactive list shows email, 5h, weekly, last activity):
84
+
85
+ ```shell
86
+ codex-auth switch # arrow + number input
87
+ ```
88
+
89
+ ![command switch](https://github.com/user-attachments/assets/48a86acf-2a6e-4206-a8c4-591989fdc0df)
90
+
91
+ Switch account non-interactively (for scripts/other CLIs):
92
+
93
+ ```shell
94
+ codex-auth switch user
95
+ ```
96
+
97
+ If multiple accounts match, interactive selection is shown.
98
+
99
+ Remove accounts (interactive multi-select):
100
+
101
+ ```shell
102
+ codex-auth remove
103
+ ```
package/bin/codex-auth ADDED
Binary file
package/package.json ADDED
@@ -0,0 +1,28 @@
1
+ {
2
+ "name": "@loongphy/codex-auth-linux-x64",
3
+ "version": "0.1.4-rc.1",
4
+ "description": "@loongphy/codex-auth binary for linux x64",
5
+ "license": "MIT",
6
+ "repository": {
7
+ "type": "git",
8
+ "url": "git+https://github.com/loongphy/codex-auth.git"
9
+ },
10
+ "homepage": "https://github.com/loongphy/codex-auth",
11
+ "bugs": {
12
+ "url": "https://github.com/loongphy/codex-auth/issues"
13
+ },
14
+ "os": [
15
+ "linux"
16
+ ],
17
+ "cpu": [
18
+ "x64"
19
+ ],
20
+ "files": [
21
+ "bin/",
22
+ "LICENSE",
23
+ "README.md"
24
+ ],
25
+ "publishConfig": {
26
+ "access": "public"
27
+ }
28
+ }