@mailgo-cli/mailgo 1.0.0

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.
Files changed (2) hide show
  1. package/bin/mailgo +39 -0
  2. package/package.json +29 -0
package/bin/mailgo ADDED
@@ -0,0 +1,39 @@
1
+ #!/usr/bin/env node
2
+
3
+ const { execFileSync } = require('child_process')
4
+
5
+ const packageName = '@mailgo-cli/mailgo'
6
+
7
+ const platformPackages = {
8
+ 'darwin-x64': `${packageName}-darwin-x64`,
9
+ 'darwin-arm64': `${packageName}-darwin-arm64`,
10
+ 'linux-x64': `${packageName}-linux-x64`,
11
+ 'linux-arm64': `${packageName}-linux-arm64`,
12
+ 'win32-x64': `${packageName}-win32-x64`,
13
+ 'win32-arm64': `${packageName}-win32-arm64`
14
+ }
15
+
16
+ function getBinaryPath() {
17
+ const platformKey = `${process.platform}-${process.arch}`
18
+ const platformPackageName = platformPackages[platformKey]
19
+
20
+ if (!platformPackageName) {
21
+ console.error(`mailgo: unsupported platform ${platformKey}`)
22
+ process.exit(1)
23
+ }
24
+
25
+ try {
26
+ const binaryName = process.platform === 'win32' ? 'mailgo.exe' : 'mailgo'
27
+ return require.resolve(`${platformPackageName}/bin/${binaryName}`)
28
+ } catch (e) {
29
+ console.error(`mailgo: platform package ${platformPackageName} not found`)
30
+ process.exit(1)
31
+ }
32
+ }
33
+
34
+ try {
35
+ const binaryPath = getBinaryPath()
36
+ execFileSync(binaryPath, process.argv.slice(2), { stdio: 'inherit' })
37
+ } catch (error) {
38
+ process.exit(error.status ?? 1)
39
+ }
package/package.json ADDED
@@ -0,0 +1,29 @@
1
+ {
2
+ "name": "@mailgo-cli/mailgo",
3
+ "version": "1.0.0",
4
+ "description": "Verify email deliverability via syntax checks and live SMTP handshake — catch bad addresses before you send",
5
+ "bin": {
6
+ "mailgo": "bin/mailgo"
7
+ },
8
+ "optionalDependencies": {
9
+
10
+ },
11
+ "keywords": ["email", "smtp", "cli", "deliverability", "email-verification", "email-validation", "catch-all", "bulk-email", "mailbox", "go"],
12
+ "author": "Hrid-a",
13
+ "license": "MIT",
14
+ "repository": {
15
+ "type": "git",
16
+ "url": "https://github.com/Hrid-a/mailgo.git"
17
+ },
18
+ "bugs": {
19
+ "url": "https://github.com/Hrid-a/mailgo/issues"
20
+ },
21
+ "homepage": "https://github.com/Hrid-a/mailgo",
22
+ "engines": {
23
+ "node": ">=14.0.0"
24
+ },
25
+ "files": [
26
+ "bin/",
27
+ "README.md"
28
+ ]
29
+ }