Compare commits
No commits in common. "main" and "0.4.1" have entirely different histories.
|
|
@ -42,8 +42,3 @@ deno install \
|
||||||
# OR
|
# OR
|
||||||
./cohamail <subcommand> -h
|
./cohamail <subcommand> -h
|
||||||
```
|
```
|
||||||
|
|
||||||
## Configuration
|
|
||||||
|
|
||||||
You can override default config and templates with your own in
|
|
||||||
`/etc/cohabit/mailer/(config|templates)/`.
|
|
||||||
|
|
|
||||||
|
|
@ -19,7 +19,7 @@ for (const template of Object.values(defaultTemplates)) {
|
||||||
}
|
}
|
||||||
|
|
||||||
//Load local templates
|
//Load local templates
|
||||||
const basePath = '/etc/cohabit/mailer/templates'
|
const basePath = '/etc/cohabit/mailer'
|
||||||
|
|
||||||
if (await exists(basePath)) {
|
if (await exists(basePath)) {
|
||||||
for await (const template of Deno.readDir(basePath)) {
|
for await (const template of Deno.readDir(basePath)) {
|
||||||
|
|
|
||||||
|
|
@ -37,7 +37,7 @@ async function readJsonFile<
|
||||||
return { ...defaultValue, ...json }
|
return { ...defaultValue, ...json }
|
||||||
}
|
}
|
||||||
|
|
||||||
const basePath = '/ect/cohabit/mailer/config'
|
const basePath = '/ect/cohabit/mailer'
|
||||||
|
|
||||||
export const accounts = await readJsonFile<AccountRecord>(
|
export const accounts = await readJsonFile<AccountRecord>(
|
||||||
`${basePath}/account.json`,
|
`${basePath}/account.json`,
|
||||||
|
|
|
||||||
|
|
@ -1,6 +1,6 @@
|
||||||
{
|
{
|
||||||
"name": "@cohabit/mailer",
|
"name": "@cohabit/mailer",
|
||||||
"version": "0.5.2",
|
"version": "0.3.3",
|
||||||
"exports": {
|
"exports": {
|
||||||
".": "./mod.ts",
|
".": "./mod.ts",
|
||||||
"./cli": "./cli.ts",
|
"./cli": "./cli.ts",
|
||||||
|
|
@ -8,8 +8,8 @@
|
||||||
"./templates": "./templates/mod.ts"
|
"./templates": "./templates/mod.ts"
|
||||||
},
|
},
|
||||||
"tasks": {
|
"tasks": {
|
||||||
"compile": "deno compile --allow-read --allow-env --allow-net=0.0.0.0,jsr.io --allow-sys=osRelease,networkInterfaces --allow-run=/usr/sbin/sendmail,whoami --output=bin/mailer --target=x86_64-unknown-linux-gnu ./cli.ts",
|
"compile": "deno compile --allow-read --allow-env --allow-net=0.0.0.0 --allow-sys=osRelease,networkInterfaces --allow-run=/usr/sbin/sendmail,whoami --output=bin/mailer --target=x86_64-unknown-linux-gnu ./cli.ts",
|
||||||
"cli": "deno run --allow-read --allow-env --allow-net=0.0.0.0,jsr.io --allow-sys=osRelease,networkInterfaces --allow-run=/usr/sbin/sendmail,whoami ./cli.ts"
|
"cli": "deno run --allow-read --allow-env --allow-net=0.0.0.0 --allow-sys=osRelease,networkInterfaces --allow-run=/usr/sbin/sendmail,whoami ./cli.ts"
|
||||||
},
|
},
|
||||||
"fmt": {
|
"fmt": {
|
||||||
"singleQuote": true,
|
"singleQuote": true,
|
||||||
|
|
@ -31,6 +31,5 @@
|
||||||
"compilerOptions": {
|
"compilerOptions": {
|
||||||
"jsx": "react-jsx",
|
"jsx": "react-jsx",
|
||||||
"jsxImportSource": "preact"
|
"jsxImportSource": "preact"
|
||||||
},
|
}
|
||||||
"license": "MIT"
|
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue