init
This commit is contained in:
commit
fa0f682c22
|
@ -0,0 +1,3 @@
|
|||
cert.pem
|
||||
key.pem
|
||||
node_modules
|
|
@ -0,0 +1,20 @@
|
|||
# welcome
|
||||
|
||||
i am grant:) a software engineer^^
|
||||
|
||||
## langauges:
|
||||
|
||||
* js (ts,node.js)
|
||||
* rust (barley)
|
||||
* c/c++
|
||||
* clojure
|
||||
|
||||
### learning (or plan to):
|
||||
|
||||
* carbon
|
||||
* asm
|
||||
|
||||
|
||||
## contacts:
|
||||
|
||||
=> mailto:grantsquires@disroot.org grantsquires@disroot.org
|
File diff suppressed because it is too large
Load Diff
|
@ -0,0 +1,10 @@
|
|||
{
|
||||
"dependencies": {
|
||||
"fs": "^0.0.1-security",
|
||||
"gemini-express": "^1.0.0",
|
||||
"gemini-server": "^2.0.0"
|
||||
},
|
||||
"devDependencies": {
|
||||
"@types/node": "^18.11.9"
|
||||
}
|
||||
}
|
|
@ -0,0 +1,18 @@
|
|||
import { readFileSync } from "fs";
|
||||
import gemini, { Request, Response, TitanRequest, NextFunction } from "gemini-server";
|
||||
|
||||
const options = {
|
||||
cert: readFileSync("cert.pem"),
|
||||
key: readFileSync("key.pem"),
|
||||
};
|
||||
|
||||
const app = gemini(options);
|
||||
|
||||
app.on("/", (_req: Request, res: Response) => {
|
||||
res.file("index.gemini");
|
||||
});
|
||||
|
||||
|
||||
app.listen(() => {
|
||||
console.log("Listening...");
|
||||
});
|
Loading…
Reference in New Issue