mirror of
https://github.com/lune-org/lune.git
synced 2024-12-12 13:00:37 +00:00
Start migration to using gitbook for docs
This commit is contained in:
parent
e17b25708b
commit
d0094ec0d1
13 changed files with 58 additions and 124 deletions
5
.gitbook.yaml
Normal file
5
.gitbook.yaml
Normal file
|
@ -0,0 +1,5 @@
|
||||||
|
root: ./docs
|
||||||
|
|
||||||
|
structure:
|
||||||
|
readme: ../README.md
|
||||||
|
summary: ./SUMMARY.md
|
41
.github/workflows/wiki.yaml
vendored
41
.github/workflows/wiki.yaml
vendored
|
@ -1,41 +0,0 @@
|
||||||
name: Deploy GitHub Wiki
|
|
||||||
|
|
||||||
on:
|
|
||||||
push:
|
|
||||||
branches:
|
|
||||||
- main
|
|
||||||
|
|
||||||
permissions:
|
|
||||||
contents: write
|
|
||||||
|
|
||||||
jobs:
|
|
||||||
wiki:
|
|
||||||
name: Deploy GitHub Wiki
|
|
||||||
runs-on: ubuntu-latest
|
|
||||||
|
|
||||||
steps:
|
|
||||||
- name: Checkout repository
|
|
||||||
uses: actions/checkout@v3
|
|
||||||
|
|
||||||
- name: Install Rust
|
|
||||||
uses: dtolnay/rust-toolchain@stable
|
|
||||||
|
|
||||||
- name: Build CLI
|
|
||||||
shell: bash
|
|
||||||
run: cargo build --package lune-cli
|
|
||||||
|
|
||||||
- name: Copy docs pages
|
|
||||||
shell: bash
|
|
||||||
run: cp -R docs/pages/ wiki
|
|
||||||
|
|
||||||
- name: Generate wiki using CLI
|
|
||||||
shell: bash
|
|
||||||
run: cargo run --package lune-cli -- --generate-wiki-dir
|
|
||||||
|
|
||||||
- name: Push wiki changes
|
|
||||||
uses: Andrew-Chen-Wang/github-wiki-action@v3
|
|
||||||
env:
|
|
||||||
WIKI_DIR: wiki/
|
|
||||||
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
|
||||||
GH_MAIL: ${{ secrets.WIKI_GITHUB_EMAIL }}
|
|
||||||
GH_NAME: ${{ github.repository_owner }}
|
|
25
docs/SUMMARY.md
Normal file
25
docs/SUMMARY.md
Normal file
|
@ -0,0 +1,25 @@
|
||||||
|
# Summary
|
||||||
|
|
||||||
|
## Home
|
||||||
|
|
||||||
|
- [Intro](pages/home/Intro.md)
|
||||||
|
- [Installation](pages/home/Installation.md)
|
||||||
|
- [Writing Scripts](pages/home/WritingScripts.md)
|
||||||
|
- [Running Scripts](pages/home/RunningScripts.md)
|
||||||
|
- [Editor Setup](pages/home/EditorSetup.md)
|
||||||
|
|
||||||
|
## Roblox
|
||||||
|
|
||||||
|
- [Intro](pages/roblox/Introduction.md)
|
||||||
|
- [Examples](pages/roblox/Examples.md)
|
||||||
|
- [API Status](pages/roblox/ApiStatus.md)
|
||||||
|
|
||||||
|
## API Reference
|
||||||
|
|
||||||
|
- [fs](pages/api/fs.md)
|
||||||
|
- [net](pages/api/net.md)
|
||||||
|
- [process](pages/api/process.md)
|
||||||
|
- [roblox](pages/api/roblox.md)
|
||||||
|
- [serde](pages/api/serde.md)
|
||||||
|
- [stdio](pages/api/stdio.md)
|
||||||
|
- [task](pages/api/task.md)
|
|
@ -1,9 +0,0 @@
|
||||||
# 🏠 Home
|
|
||||||
|
|
||||||
Welcome to the Lune wiki!
|
|
||||||
|
|
||||||
Here you can find tutorials as well as a full API reference for all of Lune's built-in APIs.
|
|
||||||
|
|
||||||
If you are just getting started, head over to the [installation](https://github.com/filiptibell/lune/wiki/Getting-Started---1-Installation) page!
|
|
||||||
|
|
||||||
Anything else can be found in the navigation sidebar.
|
|
|
@ -1,23 +0,0 @@
|
||||||
<!-- markdownlint-disable MD025 -->
|
|
||||||
|
|
||||||
# Home
|
|
||||||
|
|
||||||
- [Getting Started](https://github.com/filiptibell/lune/wiki)
|
|
||||||
- [1. Installation](https://github.com/filiptibell/lune/wiki/Getting-Started---1-Installation)
|
|
||||||
- [2. Writing Scripts](https://github.com/filiptibell/lune/wiki/Getting-Started---2-Writing-Scripts)
|
|
||||||
- [3. Running Scripts](https://github.com/filiptibell/lune/wiki/Getting-Started---3-Running-Scripts)
|
|
||||||
- [4. Editor Setup](https://github.com/filiptibell/lune/wiki/Getting-Started---4-Editor-Setup)
|
|
||||||
|
|
||||||
# Roblox
|
|
||||||
|
|
||||||
- [Getting Started](https://github.com/filiptibell/lune/wiki/Roblox)
|
|
||||||
- [API Reference](https://github.com/filiptibell/lune/wiki/Roblox---API-Reference)
|
|
||||||
|
|
||||||
# API Reference
|
|
||||||
|
|
||||||
- [FS](https://github.com/filiptibell/lune/wiki/API-Reference---FS)
|
|
||||||
- [Net](https://github.com/filiptibell/lune/wiki/API-Reference---Net)
|
|
||||||
- [Process](https://github.com/filiptibell/lune/wiki/API-Reference---Process)
|
|
||||||
- [Stdio](https://github.com/filiptibell/lune/wiki/API-Reference---Stdio)
|
|
||||||
- [Task](https://github.com/filiptibell/lune/wiki/API-Reference---Task)
|
|
||||||
- [Uncategorized](https://github.com/filiptibell/lune/wiki/API-Reference---Uncategorized)
|
|
7
docs/pages/home/Intro.md
Normal file
7
docs/pages/home/Intro.md
Normal file
|
@ -0,0 +1,7 @@
|
||||||
|
# 🏠 Home
|
||||||
|
|
||||||
|
Welcome to the Lune docs site!
|
||||||
|
|
||||||
|
Here you can find tutorials as well as a full API reference for all of Lune's built-in APIs.
|
||||||
|
|
||||||
|
To get started, head over to the [Installation](https://github.com/filiptibell/lune/wiki/Getting-Started---1-Installation) page.
|
|
@ -1,48 +1,12 @@
|
||||||
<!-- markdownlint-disable MD041 -->
|
<!-- markdownlint-disable MD041 -->
|
||||||
|
<!-- markdownlint-disable MD033 -->
|
||||||
|
|
||||||
# API Reference
|
# API Status
|
||||||
|
|
||||||
Welcome to the API reference page for the built-in `roblox` library!
|
This is a page indicating the current implementation status for instance methods and datatypes in the `roblox` library.
|
||||||
|
|
||||||
All of the following static functions, classes, and datatypes can be imported using `require("@lune/roblox")`.
|
If an API on a class is not listed here it may not be within the scope for Lune and may not be implemented in the future. <br />
|
||||||
|
However, if a recently added datatype is missing, and it can be used as an instance property, it is likely that it will be implemented.
|
||||||
## Static Functions
|
|
||||||
|
|
||||||
### `readPlaceFile`
|
|
||||||
|
|
||||||
Reads a place file into a DataModel instance.
|
|
||||||
|
|
||||||
```lua
|
|
||||||
local roblox = require("@lune/roblox")
|
|
||||||
local game = roblox.readPlaceFile("filePath.rbxl")
|
|
||||||
```
|
|
||||||
|
|
||||||
### `readModelFile`
|
|
||||||
|
|
||||||
Reads a model file into a table of instances.
|
|
||||||
|
|
||||||
```lua
|
|
||||||
local roblox = require("@lune/roblox")
|
|
||||||
local instances = roblox.readModelFile("filePath.rbxm")
|
|
||||||
```
|
|
||||||
|
|
||||||
### `writePlaceFile`
|
|
||||||
|
|
||||||
Writes a DataModel instance to a place file.
|
|
||||||
|
|
||||||
```lua
|
|
||||||
local roblox = require("@lune/roblox")
|
|
||||||
roblox.writePlaceFile("filePath.rbxl", game)
|
|
||||||
```
|
|
||||||
|
|
||||||
### `writeModelFile`
|
|
||||||
|
|
||||||
Writes one or more instances to a model file.
|
|
||||||
|
|
||||||
```lua
|
|
||||||
local roblox = require("@lune/roblox")
|
|
||||||
roblox.writeModelFile("filePath.rbxm", { instance1, instance2, ... })
|
|
||||||
```
|
|
||||||
|
|
||||||
## Classes
|
## Classes
|
||||||
|
|
||||||
|
@ -109,4 +73,4 @@ Currently implemented datatypes:
|
||||||
- [`Vector3`](https://create.roblox.com/docs/reference/engine/datatypes/Vector3)
|
- [`Vector3`](https://create.roblox.com/docs/reference/engine/datatypes/Vector3)
|
||||||
- [`Vector3int16`](https://create.roblox.com/docs/reference/engine/datatypes/Vector3int16)
|
- [`Vector3int16`](https://create.roblox.com/docs/reference/engine/datatypes/Vector3int16)
|
||||||
|
|
||||||
Note that these datatypes are kept as up-to-date as possible, but some very new members may be missing.
|
Note that these datatypes are kept as up-to-date as possible, but recently added members & methods may be missing.
|
|
@ -1,15 +1,11 @@
|
||||||
<!-- markdownlint-disable MD033 -->
|
<!-- markdownlint-disable MD033 -->
|
||||||
<!-- markdownlint-disable MD026 -->
|
<!-- markdownlint-disable MD026 -->
|
||||||
|
|
||||||
# ✏️ Writing Lune Scripts for Roblox
|
# Example Lune Scripts for Roblox
|
||||||
|
|
||||||
Lune has a powerful built-in library and set of APIs for manipulating Roblox place files and model files. It contains APIs for reading & writing files, and gives you instances to use, just as if you were scripting inside of the Roblox engine, albeit with a more limited API.
|
These are a few examples of things you can do using the built-in `roblox` library.
|
||||||
|
|
||||||
For a full list of the currently implemented APIs, check out the [API Reference](https://github.com/filiptibell/lune/wiki/Roblox---API-Reference) page.
|
## `1` - Make all parts anchored in a place file
|
||||||
|
|
||||||
## Example Scripts
|
|
||||||
|
|
||||||
### `1` - Make all parts anchored in a place file
|
|
||||||
|
|
||||||
```lua
|
```lua
|
||||||
local roblox = require("@lune/roblox")
|
local roblox = require("@lune/roblox")
|
||||||
|
@ -32,7 +28,7 @@ roblox.writePlaceFile("myPlaceFile.rbxl")
|
||||||
|
|
||||||
---
|
---
|
||||||
|
|
||||||
### `2` - Save instances in a place as individual model files
|
## `2` - Save instances in a place as individual model files
|
||||||
|
|
||||||
```lua
|
```lua
|
||||||
local roblox = require("@lune/roblox")
|
local roblox = require("@lune/roblox")
|
||||||
|
@ -54,7 +50,7 @@ end
|
||||||
|
|
||||||
---
|
---
|
||||||
|
|
||||||
### `3` - Make a new place from scratch
|
## `3` - Make a new place from scratch
|
||||||
|
|
||||||
```lua
|
```lua
|
||||||
local roblox = require("@lune/roblox")
|
local roblox = require("@lune/roblox")
|
10
docs/pages/roblox/Intro.md
Normal file
10
docs/pages/roblox/Intro.md
Normal file
|
@ -0,0 +1,10 @@
|
||||||
|
<!-- markdownlint-disable MD033 -->
|
||||||
|
<!-- markdownlint-disable MD026 -->
|
||||||
|
|
||||||
|
# ✏️ Writing Lune Scripts for Roblox
|
||||||
|
|
||||||
|
Lune has a powerful built-in library and set of APIs for manipulating Roblox place files and model files. It contains APIs for reading & writing files, and gives you instances to use, just as if you were scripting inside of the Roblox engine, albeit with a more limited API.
|
||||||
|
|
||||||
|
For examples on how to write Roblox-specific Lune scripts, check out the [Examples](https://github.com/filiptibell/lune/wiki/Roblox---Examples) page.
|
||||||
|
|
||||||
|
For a full list of the currently implemented Roblox APIs, check out the [API Reference](https://github.com/filiptibell/lune/wiki/Roblox---API-Reference) page.
|
Loading…
Reference in a new issue