https://github.com/lafkpages/crosis
🗿Crosis done just right
https://github.com/lafkpages/crosis
client crosis goval lib node replit typescript
Last synced: 8 months ago
JSON representation
🗿Crosis done just right
- Host: GitHub
- URL: https://github.com/lafkpages/crosis
- Owner: lafkpages
- License: agpl-3.0
- Created: 2023-07-09T18:46:55.000Z (over 2 years ago)
- Default Branch: main
- Last Pushed: 2024-06-18T11:27:36.000Z (over 1 year ago)
- Last Synced: 2024-10-29T21:05:00.094Z (over 1 year ago)
- Topics: client, crosis, goval, lib, node, replit, typescript
- Language: TypeScript
- Homepage: https://lafkpages.github.io/crosis/
- Size: 296 KB
- Stars: 6
- Watchers: 1
- Forks: 0
- Open Issues: 3
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README



**crosis** is a NPM package that allows you to programmatically interact with your Replit Repl.
Our goal is to make this process as easy and simple as possible.
# 🔥Features
- 📄 File manipulation
- 📁 Folder manipulation
- 📠 Command execution
- 📲 Easy log in process
- 🚀 Performance
# Installation & Usage
Install the package by running `npm install crosis`.
You can use the package in both CommonJS and ESM.
# Example
```js
// Import the crosis package
// CommonJS
const { Crosis } = require("crosis");
// OR
// ESM
import { Crosis } from "crosis";
// Create a Crosis object
// You can connect to a Replit repl using the adapterReplit() function
const crosis = new Crosis({
adapter: adapterReplit({
replId: YOUR_REPL_ID,
sid: YOUR_REPLIT_SID,
}),
});
// You can also specify a goval url
const crosis = new Crosis({
url: "your goval url",
});
// Connect crosis
crosis.connect().then(async () => {
console.log("Crosis connected");
// Read files of repl
const files = await crosis.readDir(".");
// List files
files.forEach((file) => {
console.log(file);
});
// Disconnect crosis at the end of the script
// Terminating or ending the script will also disconnect crosis
await crosis.disconnect();
});
```
# Contributing
Contributions are always welcome! If you want to contribute, feel free to open a pull request.
# License
The crosis package is licensed under the AGPL-3.0 License. See LICENSE for more information.