https://github.com/0xtadash1/redeqo
Get a different look for your website, specialized for terminals! -- Web-based template engine for terminals
https://github.com/0xtadash1/redeqo
ansi ansi-colors api business-card cli curl shell template-engine
Last synced: 3 months ago
JSON representation
Get a different look for your website, specialized for terminals! -- Web-based template engine for terminals
- Host: GitHub
- URL: https://github.com/0xtadash1/redeqo
- Owner: 0xTadash1
- License: mit
- Created: 2021-11-10T08:26:21.000Z (over 3 years ago)
- Default Branch: main
- Last Pushed: 2021-11-19T09:03:50.000Z (over 3 years ago)
- Last Synced: 2024-01-22T23:26:08.423Z (over 1 year ago)
- Topics: ansi, ansi-colors, api, business-card, cli, curl, shell, template-engine
- Language: JavaScript
- Homepage:
- Size: 40 KB
- Stars: 1
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# redeqo
Web-based template mapper for terminals.
Map your website (blog, portfolio, project wiki, etc) contents to
plain text, shell scripts, Python or others.Also, You can share the URL and anybody can show or run the response via **`curl`**.
## Example
```sh
curl "https://redeqo.deta.dev/?s=https://0xtadash1.github.io/redeqo/"
```
or colorful version
```sh
echo -e """$(curl -s "https://redeqo.deta.dev/?s=https://0xtadash1.github.io/redeqo/&d=pj-intro-card.ansi.njk")"""
```
The first defines the template to be used by `` in `?s=...` HTML.
The second overrides it with another template in `&d=...` query.## TODO
- Configuring
- [ ] Njk `env` by ``/query
- [ ] JSDom's options by ``/query
- [ ] `runScripts`---
- Custom Filtters/Tags(Extensions)
- [ ] ANSI Color Codes (use `chalk` module)
- [ ] `strip`: Alias for `striptags(true)`
- [ ] `sindent(n=4, doIndentFirstLine=false)`: `strip()` and `indent()`
- [ ] `si-wrap(len, n=4, doIndentFirstLine=false)`: `sindent()` and Line-wrapping. `len` is line-length.---
- Other
- [x] RootPage without queries such as `?src=...`
- [x] User-Agent == curl
- [x] else
- [ ] Documents
- [ ] Sample/Default templates
- [ ] ANSI Colored
- [ ] Bash
- [ ] Python## Develop
### Run
1. Start server
```sh
IS_DEBUG=true node index.js
```
1. Test `curl`
```sh
curl "http://localhost:3000/"
```
```
redeqo -- Web-based template mapper for terminals
https://github.com/0xTadash1/redeqo
```
or
```sh
curl "https://localhost:3000/?s=https://0xtadash1.github.io/redeqo/"
```
```
=============================================================================
redeqo
-----------------------------------------------------------------------------
Get a different look for your website, specialized for terminals!---
Web-based template mapper for terminals.
Map your website (blog, portfolio, project wiki, etc) contents to
plain text, shell scripts, Python or others.Also, You can share the URL and anybody can show or run the response via curl.
---
Home https://0xTadash1.github.io/redeqo
Doc https://github.com/0xTadash1/redeqo/blob/main/README.md
Repo https://github.com/0xTadash1/redeqo
License MIT
https://github.com/0xTadash1/redeqo/blob/main/LICENSE=============================================================================
```### Deploy
```sh
deta deploy
```### env vars (for debug)
These are case-sensitive.
- `IS_DEBUG`, default: `false`
- `true` || anything else (null, `false`, `False`, `0`, `1`, `True`, etc.)
- `PORT`, default: `3000`
- numeric || anything else