@mmmbuto/masix 0.1.0-beta.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/README.md ADDED
@@ -0,0 +1,60 @@
1
+ # @mmmbuto/masix
2
+
3
+ Scoped Termux package for MasiX.
4
+
5
+ MasiX is a Rust-first messaging automation runtime inspired by OpenClaw and rebuilt for stability, speed, and mobile execution.
6
+
7
+ ## Function Summary
8
+
9
+ - Telegram bot automation with interactive inline menus
10
+ - Real MCP tool-calling flow through OpenAI-compatible providers
11
+ - Natural-language reminder scheduling (cron persistence)
12
+ - Optional WhatsApp and SMS integrations
13
+ - SOUL.md startup memory context
14
+
15
+ ## Install (Termux)
16
+
17
+ ```bash
18
+ pkg update -y
19
+ pkg install -y rust nodejs-lts termux-api
20
+ npm install -g @mmmbuto/masix
21
+ masix --help
22
+ ```
23
+
24
+ ## Quick Start
25
+
26
+ ```bash
27
+ masix config init
28
+ # edit ~/.config/masix/config.toml
29
+ masix start
30
+ ```
31
+
32
+ ## Useful Commands
33
+
34
+ ```bash
35
+ masix start
36
+ masix config show
37
+ masix cron add 'domani alle 9 "Daily check"'
38
+ masix cron list
39
+ masix cron cancel 1
40
+ masix stats
41
+ ```
42
+
43
+ ## Notes
44
+
45
+ - This package targets Android + arm64 (Termux environments)
46
+ - If no prebuilt binary is available, postinstall builds from source
47
+
48
+ ## Full Documentation
49
+
50
+ - Repository README: `../../README.md`
51
+ - Detailed guide: `../../docs/USER_GUIDE.md`
52
+
53
+ If you publish on GitHub, use:
54
+
55
+ - `https://github.com/<your-org>/masix`
56
+ - `https://github.com/<your-org>/masix/blob/main/docs/USER_GUIDE.md`
57
+
58
+ ## License
59
+
60
+ MIT - See `../../LICENSE`
package/install.js ADDED
@@ -0,0 +1,64 @@
1
+ const fs = require('fs');
2
+ const path = require('path');
3
+ const { execSync } = require('child_process');
4
+
5
+ const BINARY_NAME = 'masix';
6
+ const BIN_DIR = path.join(__dirname, '..', 'bin');
7
+ const BIN_PATH = path.join(BIN_DIR, BINARY_NAME);
8
+
9
+ // Check if running in Termux
10
+ const isTermux = process.env.TERMUX_VERSION !== undefined ||
11
+ process.env.PREFIX === '/data/data/com.termux/files/usr';
12
+
13
+ if (!isTermux) {
14
+ console.warn('āš ļø @mmmbuto/masix is designed for Android Termux only!');
15
+ console.warn(' Installation may fail on other platforms.');
16
+ }
17
+
18
+ // Create bin directory
19
+ if (!fs.existsSync(BIN_DIR)) {
20
+ fs.mkdirSync(BIN_DIR, { recursive: true });
21
+ }
22
+
23
+ // Check if prebuilt binary exists
24
+ const prebuiltPath = path.join(__dirname, 'prebuilt', BINARY_NAME);
25
+
26
+ if (fs.existsSync(prebuiltPath)) {
27
+ console.log('āœ… Installing prebuilt masix binary...');
28
+ fs.copyFileSync(prebuiltPath, BIN_PATH);
29
+ fs.chmodSync(BIN_PATH, 0o755);
30
+ console.log(`āœ… Binary installed at: ${BIN_PATH}`);
31
+ } else {
32
+ console.log('šŸ”Ø No prebuilt binary found. Building from source...');
33
+ console.log(' This requires Rust to be installed in Termux.');
34
+
35
+ try {
36
+ const masixRoot = path.join(__dirname, '..', '..');
37
+ execSync('cargo build --release', {
38
+ cwd: masixRoot,
39
+ stdio: 'inherit'
40
+ });
41
+
42
+ let sourceBinary = path.join(masixRoot, 'target', 'release', BINARY_NAME);
43
+ if (!fs.existsSync(sourceBinary)) {
44
+ sourceBinary = path.join(masixRoot, 'target', 'aarch64-linux-android', 'release', BINARY_NAME);
45
+ }
46
+
47
+ if (fs.existsSync(sourceBinary)) {
48
+ fs.copyFileSync(sourceBinary, BIN_PATH);
49
+ fs.chmodSync(BIN_PATH, 0o755);
50
+ console.log(`āœ… Binary built and installed at: ${BIN_PATH}`);
51
+ } else {
52
+ throw new Error('Binary not found after build');
53
+ }
54
+ } catch (error) {
55
+ console.error('āŒ Build failed:', error.message);
56
+ console.error('\nšŸ“¦ Please install Rust in Termux:');
57
+ console.error(' pkg install rust\n');
58
+ process.exit(1);
59
+ }
60
+ }
61
+
62
+ console.log('\nšŸŽ‰ masix installed successfully!');
63
+ console.log(' Run "masix --help" to get started.');
64
+ console.log(' Run "masix config init" to create default config.\n');
package/package.json ADDED
@@ -0,0 +1,45 @@
1
+ {
2
+ "name": "@mmmbuto/masix",
3
+ "version": "0.1.0-beta.1",
4
+ "description": "MIT Messaging Agent for Termux - Telegram, WhatsApp, SMS with MCP + Cron",
5
+ "main": "index.js",
6
+ "files": [
7
+ "README.md",
8
+ "install.js",
9
+ "prebuilt/"
10
+ ],
11
+ "bin": {
12
+ "masix": "./bin/masix"
13
+ },
14
+ "scripts": {
15
+ "postinstall": "node install.js",
16
+ "test": "echo \"Error: no test specified\" && exit 1"
17
+ },
18
+ "keywords": [
19
+ "termux",
20
+ "telegram",
21
+ "whatsapp",
22
+ "sms",
23
+ "mcp",
24
+ "cron",
25
+ "ai",
26
+ "messaging",
27
+ "android"
28
+ ],
29
+ "author": "Davide A. Guglielmi <dev@mmmbuto.com>",
30
+ "license": "MIT",
31
+ "repository": {
32
+ "type": "git",
33
+ "url": "https://github.com/DioNanos/masix.git"
34
+ },
35
+ "homepage": "https://github.com/DioNanos/masix#readme",
36
+ "publishConfig": {
37
+ "access": "public"
38
+ },
39
+ "os": [
40
+ "android"
41
+ ],
42
+ "cpu": [
43
+ "arm64"
44
+ ]
45
+ }
package/prebuilt/masix ADDED
Binary file