chirpie 1.0.0 → 1.0.2
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/dist/index.js +5 -2
- package/package.json +2 -2
package/dist/index.js
CHANGED
|
@@ -2,6 +2,7 @@
|
|
|
2
2
|
|
|
3
3
|
// src/index.ts
|
|
4
4
|
import { Command as Command9 } from "commander";
|
|
5
|
+
import { createRequire } from "module";
|
|
5
6
|
|
|
6
7
|
// src/commands/auth.ts
|
|
7
8
|
import { Command } from "commander";
|
|
@@ -148,7 +149,7 @@ function getClient() {
|
|
|
148
149
|
}
|
|
149
150
|
|
|
150
151
|
// src/commands/post.ts
|
|
151
|
-
var postCommand = new Command3("post").description("Create a post on X").argument("<text>", "Post text (max 280 chars)").option("-a, --account <id>", "Account ID").option("-m, --media <urls...>", "Media URLs (up to 4 images or 1 video)").option("-s, --schedule <datetime>", "Schedule for later (ISO 8601)").option("--json", "Output raw JSON").action(async (text, opts) => {
|
|
152
|
+
var postCommand = new Command3("post").description("Create a post on X").argument("<text>", "Post text (max 280 chars, or 25,000 for X Premium accounts)").option("-a, --account <id>", "Account ID").option("-m, --media <urls...>", "Media URLs (up to 4 images or 1 video)").option("-s, --schedule <datetime>", "Schedule for later (ISO 8601)").option("--json", "Output raw JSON").action(async (text, opts) => {
|
|
152
153
|
const client = getClient();
|
|
153
154
|
let accountId = opts.account;
|
|
154
155
|
if (!accountId) {
|
|
@@ -398,7 +399,9 @@ keysCommand.command("revoke <id>").description("Revoke an API key").action(async
|
|
|
398
399
|
});
|
|
399
400
|
|
|
400
401
|
// src/index.ts
|
|
401
|
-
var
|
|
402
|
+
var require2 = createRequire(import.meta.url);
|
|
403
|
+
var { version } = require2("../package.json");
|
|
404
|
+
var program = new Command9().name("chirpie").description("Chirpie \u2014 the social media layer for AI agents").version(version);
|
|
402
405
|
program.addCommand(loginCommand);
|
|
403
406
|
program.addCommand(logoutCommand);
|
|
404
407
|
program.addCommand(authCommand);
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "chirpie",
|
|
3
|
-
"version": "1.0.
|
|
3
|
+
"version": "1.0.2",
|
|
4
4
|
"description": "Chirpie CLI — post to social media from the command line",
|
|
5
5
|
"repository": {
|
|
6
6
|
"type": "git",
|
|
@@ -31,7 +31,7 @@
|
|
|
31
31
|
],
|
|
32
32
|
"license": "MIT",
|
|
33
33
|
"dependencies": {
|
|
34
|
-
"@chirpie/sdk": "^1.0.
|
|
34
|
+
"@chirpie/sdk": "^1.0.1",
|
|
35
35
|
"commander": "^13"
|
|
36
36
|
},
|
|
37
37
|
"devDependencies": {
|