1
1
Fork 0
mirror of https://github.com/azur1s/bobbylisp.git synced 2024-10-16 02:37:40 -05:00

rebrand: vy

This commit is contained in:
Natapat Samutpong 2022-02-08 23:04:47 +07:00
parent 5d9d0f700b
commit 841f007b44
29 changed files with 49 additions and 55 deletions

16
Cargo.lock generated
View file

@ -37,14 +37,6 @@ version = "1.3.2"
source = "registry+https://github.com/rust-lang/crates.io-index" source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "bef38d45163c2f1dde094a7dfd33ccf595c92905c8f8f4fdc18d06fb1037718a" checksum = "bef38d45163c2f1dde094a7dfd33ccf595c92905c8f8f4fdc18d06fb1037718a"
[[package]]
name = "blspc"
version = "0.1.0"
dependencies = [
"regex",
"structopt",
]
[[package]] [[package]]
name = "clap" name = "clap"
version = "2.34.0" version = "2.34.0"
@ -235,6 +227,14 @@ version = "0.9.4"
source = "registry+https://github.com/rust-lang/crates.io-index" source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "49874b5167b65d7193b8aba1567f5c7d93d001cafc34600cee003eda787e483f" checksum = "49874b5167b65d7193b8aba1567f5c7d93d001cafc34600cee003eda787e483f"
[[package]]
name = "vyc"
version = "0.1.0"
dependencies = [
"regex",
"structopt",
]
[[package]] [[package]]
name = "winapi" name = "winapi"
version = "0.3.9" version = "0.3.9"

View file

@ -1,4 +1,4 @@
[workspace] [workspace]
members = [ members = [
"blspc", "vyc",
] ]

View file

@ -2,11 +2,11 @@ all: build
debug: build-debug debug: build-debug
build: build:
cd ./blspc; cargo build --release cd ./vyc; cargo build --release
rm ~/bin/blspc -f rm ~/bin/vyc -f
mv ./target/release/blspc ~/bin/blspc mv ./target/release/vyc ~/bin/vyc
build-debug: build-debug:
cd ./blspc; cargo build cd ./vyc; cargo build
rm ~/bin/blspc -f rm ~/bin/vyc -f
mv ./target/debug/blspc ~/bin/blspc mv ./target/debug/vyc ~/bin/vyc

View file

@ -1,24 +1,23 @@
# <img src="https://raw.githubusercontent.com/azur1s/bobbylisp/master/assets/icon.png" width="35"> bobbylisp # vy
another lisp dialect another lisp dialect
> Also available on https://git.ablecorp.us/azur/bobbylisp
## <img src="https://raw.githubusercontent.com/azur1s/bobbylisp/master/assets/icon.png" width="25"> Installation ## Installation
```console ```console
$ bash <(curl -s https://raw.githubusercontent.com/azur1s/bobbylisp/master/install.sh) $ bash <(curl -s https://raw.githubusercontent.com/azur1s/vy/master/install.sh)
``` ```
The binary will be installed in `~/bin/blspc` run it with: The binary will be installed in `~/bin/vyc` run it with:
```console ```console
$ blspc help $ vyc help
``` ```
### <img src="https://raw.githubusercontent.com/azur1s/bobbylisp/master/assets/icon.png" width="15"> Example ### Example
```console ```console
$ blspc compile ./example/hello.blsp $ vyc compile ./example/hello.vy
$ blspc run ./hello.bsm $ vyc run ./hello.bsm
Hello, World! Hello, World!
``` ```
## <img src="https://raw.githubusercontent.com/azur1s/bobbylisp/master/assets/icon.png" width="25"> Progress: ## Progress:
DONE: DONE:
- Parsing, Compiling, Running(VM) - Parsing, Compiling, Running(VM)
- Intrinsic: - Intrinsic:

Binary file not shown.

Before

Width:  |  Height:  |  Size: 3.3 KiB

View file

@ -105,42 +105,38 @@ install() {
check_installed cargo check_installed cargo
echo "Setting up folders..." echo "Setting up folders..."
mkdir -p ~/.cache/ mkdir -p ~/.cache/
rm -rf ~/.cache/bobbylisp/ rm -rf ~/.cache/vy/
echo "Cloning repository..." echo "Cloning repository..."
cd ~/.cache/ cd ~/.cache/
git clone https://github.com/azur1s/bobbylisp git clone https://github.com/azur1s/vy
cd ~/.cache/bobbylisp/ cd ~/.cache/vy/
echo "Compiling..." echo "Compiling..."
cargo build --release cargo build --release
mv ~/.cache/bobbylisp/target/release/blspc ~/bin/blspc mv ~/.cache/vy/target/release/vyc ~/bin/vyc
clean_up "Done! Thanks a lot for trying out Bobbylisp!";; clean_up "Done! Thanks a lot for trying out vy!";;
2) 2)
echo "Testing dependencies..." echo "Testing dependencies..."
check_installed git check_installed git
check_installed cargo check_installed cargo
echo "Setting up folders..." echo "Setting up folders..."
mkdir -p ~/.cache/ mkdir -p ~/.cache/
rm -rf ~/.cache/bobbylisp/ rm -rf ~/.cache/vy/
echo "Cloning repository..." echo "Cloning repository..."
cd ~/.cache/ cd ~/.cache/
git clone https://github.com/azur1s/bobbylisp git clone https://github.com/azur1s/vy
cd ~/.cache/bobbylisp/ cd ~/.cache/vy/
echo "Compiling..." echo "Compiling..."
cargo build cargo build
mv ~/.cache/bobbylisp/target/debug/blspc ~/bin/blspc mv ~/.cache/vy/target/debug/vyc ~/bin/vyc
clean_up "Done! Thanks a lot for trying out Bobbylisp!";; clean_up "Done! Thanks a lot for trying out vy!";;
3) clean_up;; 3) clean_up;;
esac esac
} }
uninstall() { uninstall() {
echo "Uninstalling blspc..." echo "Uninstalling vyc..."
rm ~/bin/blspc -f rm ~/bin/vyc -f
rm /usr/bin/blspc -f rm /usr/bin/vyc -f
sleep 1s
echo "Uninstalling trolley..."
rm ~/bin/trolley -f
rm /usr/bin/trolley -f
sleep 1s sleep 1s
clean_up "Sad to see you go! Goodbye! o/" clean_up "Sad to see you go! Goodbye! o/"
} }

14
test.sh
View file

@ -6,17 +6,17 @@ echo $2
# if $2 equal to "noecho" # if $2 equal to "noecho"
if [ $2 = "noecho" ]; if [ $2 = "noecho" ];
then then
make debug; echo ""; blspc compile $noext.blsp; echo "" make debug; echo ""; vyc compile $noext.vy; echo ""
cat $noext.blsp; echo -e "\n"; cat $name.bsm; echo "" cat $noext.vy; echo -e "\n"; cat $name.vyir; echo ""
blspc run $name.bsm vyc run $name.vyir
else else
make debug make debug
blspc compile $noext.blsp vyc compile $noext.vy
echo -e "------------------------------------------- SOURCE" echo -e "------------------------------------------- SOURCE"
cat $noext.blsp cat $noext.vy
echo -e "\n----------------------------------------- COMPILED" echo -e "\n----------------------------------------- COMPILED"
cat $name.bsm cat $name.vyir
echo -e "------------------------------------------- OUTPUT" echo -e "------------------------------------------- OUTPUT"
blspc run $name.bsm blspc run $name.vyir
echo -e "--------------------------------------------------" echo -e "--------------------------------------------------"
fi fi

View file

View file

View file

@ -1,11 +1,10 @@
[package] [package]
name = "blspc" name = "vyc"
description = "Bobbylisp compiler." description = "vy language compiler."
version = "0.1.0" version = "0.1.0"
edition = "2021" edition = "2021"
author = ["azur1s <https://github.com/azur1s>"] homepage = "https://github.com/azur1s/vy"
homepage = "https://github.com/azur1s/bobbylisp" repository = "https://github.com/azur1s/vy"
repository = "https://github.com/azur1s/bobbylisp"
license = "AGPL-3.0" license = "AGPL-3.0"
readme = "README.md" readme = "README.md"

View file

@ -3,7 +3,7 @@ use std::path::PathBuf;
use structopt::StructOpt; use structopt::StructOpt;
#[derive(StructOpt, Debug)] #[derive(StructOpt, Debug)]
#[structopt(name = "blspc")] #[structopt(name = "vyc")]
pub struct Opts { pub struct Opts {
#[structopt(subcommand)] #[structopt(subcommand)]
pub commands: Args, pub commands: Args,