Skip to content

Commit

Permalink
Added more build platforms.
Browse files Browse the repository at this point in the history
  • Loading branch information
mkrueger committed Nov 1, 2024
1 parent 3ec7549 commit 483a644
Show file tree
Hide file tree
Showing 6 changed files with 212 additions and 6 deletions.
162 changes: 161 additions & 1 deletion .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ jobs:
mv target/release/ppld bin
mv target/release/scandb bin
mv target/release/ppl-language-server bin
- name: 'Upload deb'
- name: 'Upload zip'
uses: actions/upload-artifact@v4
with:
name: icy_board_linux_${{ env.VERSION }}
Expand All @@ -50,3 +50,163 @@ jobs:
bin/scandb
bin/ppl-language-server
file_id.diz
INSTALL.txt
build_windows:
runs-on: windows-latest
steps:
- uses: actions/checkout@v4
- name: Build
id: build
run: |
$VERSION=$(python tools\prep_diz.py "file_id.diz")
echo "Version: $VERSION"
cargo build --release
echo "Copy $DEB to icy_board.deb"
mkdir bin
move target/release/icy_board.exe bin
move target/release/icbsetup.exe bin
move target/release/icbmailer.exe bin
move target/release/icbsysmgr.exe bin
move target/release/mkicbmnu.exe bin
move target/release/mkicbtxt.exe bin
move target/release/pplc.exe bin
move target/release/ppld.exe bin
move target/release/scandb.exe bin
move target/release/ppl-language-server.exe bin
- name: 'Upload zip'
uses: actions/upload-artifact@v4
with:
name: icy_board_linux_${{ env.VERSION }}
path: |
bin/icy_board
bin/icbsetup
bin/icbmailer
bin/icbsysmgr
bin/mkicbmnu
bin/mkicbtxt
bin/pplc
bin/pppld
bin/scandb
bin/ppl-language-server
file_id.diz
INSTALL.txt
build_mac:
runs-on: macos-13
steps:
- uses: actions/checkout@v4
- name: Build
id: build
run: |
rustup target add aarch64-apple-darwin
rustup target add x86_64-apple-darwin
cargo build --release --target aarch64-apple-darwin
cargo build --release --target x86_64-apple-darwin
export version=$(python3 tools/prep_diz.py "file_id.diz")
echo "VERSION=$version" >> $GITHUB_ENV
echo "Version: $version"
cargo build --release
echo "Copy $DEB to icy_board.deb"
mkdir -p aarch64-apple-darwin/bin
mv target/aarch64-apple-darwin/release/icy_board aarch64-apple-darwin/bin
mv target/aarch64-apple-darwin/release/icbsetup aarch64-apple-darwin/bin
mv target/aarch64-apple-darwin/release/icbmailer aarch64-apple-darwin/bin
mv target/aarch64-apple-darwin/release/icbsysmgr aarch64-apple-darwin/bin
mv target/aarch64-apple-darwin/release/mkicbmnu aarch64-apple-darwin/bin
mv target/aarch64-apple-darwin/release/mkicbtxt aarch64-apple-darwin/bin
mv target/aarch64-apple-darwin/release/pplc aarch64-apple-darwin/bin
mv target/aarch64-apple-darwin/release/ppld aarch64-apple-darwin/bin
mv target/aarch64-apple-darwin/release/scandb aarch64-apple-darwin/bin
mv target/aarch64-apple-darwin/release/ppl-language-server aarch64-apple-darwin/bin
mkdir -p x86_64-apple-darwin/bin
mv target/x86_64-apple-darwin/release/icy_board x86_64-apple-darwin/bin
mv target/x86_64-apple-darwin/release/icbsetup x86_64-apple-darwin/bin
mv target/x86_64-apple-darwin/release/icbmailer x86_64-apple-darwin/bin
mv target/x86_64-apple-darwin/release/icbsysmgr x86_64-apple-darwin/bin
mv target/x86_64-apple-darwin/release/mkicbmnu x86_64-apple-darwin/bin
mv target/x86_64-apple-darwin/release/mkicbtxt x86_64-apple-darwin/bin
mv target/x86_64-apple-darwin/release/pplc x86_64-apple-darwin/bin
mv target/x86_64-apple-darwin/release/ppld x86_64-apple-darwin/bin
mv target/x86_64-apple-darwin/release/scandb x86_64-apple-darwin/bin
mv target/x86_64-apple-darwin/release/ppl-language-server x86_64-apple-darwin/bin
- name: 'Upload zip'
uses: actions/upload-artifact@v4
with:
name: icy_board_osx_aarch64-apple-darwin_${{ env.VERSION }}
path: |
aarch64-apple-darwin/bin/icy_board
aarch64-apple-darwin/bin/icbsetup
aarch64-apple-darwin/bin/icbmailer
aarch64-apple-darwin/bin/icbsysmgr
aarch64-apple-darwin/bin/mkicbmnu
aarch64-apple-darwin/bin/mkicbtxt
aarch64-apple-darwin/bin/pplc
aarch64-apple-darwin/bin/pppld
aarch64-apple-darwin/bin/scandb
aarch64-apple-darwin/bin/ppl-language-server
file_id.diz
INSTALL.txt
- name: 'Upload zip'
uses: actions/upload-artifact@v4
with:
name: icy_board_osx_x86_64-apple-darwin_${{ env.VERSION }}
path: |
x86_64-apple-darwin/bin/icy_board
x86_64-apple-darwin/bin/icbsetup
x86_64-apple-darwin/bin/icbmailer
x86_64-apple-darwin/bin/icbsysmgr
x86_64-apple-darwin/bin/mkicbmnu
x86_64-apple-darwin/bin/mkicbtxt
x86_64-apple-darwin/bin/pplc
x86_64-apple-darwin/bin/pppld
x86_64-apple-darwin/bin/scandb
x86_64-apple-darwin/bin/ppl-language-server
file_id.diz
INSTALL.txt
build_arm:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Install required libraries
run: |
sudo apt-get install build-essential libasound2-dev libxcb-shape0-dev libxcb-xfixes0-dev
rustup target add aarch64-unknown-linux-gnu
cargo install -f cross
- name: Build
id: build
run: |
export version=$(python3 tools/prep_diz.py "file_id.diz")
echo "VERSION=$version" >> $GITHUB_ENV
echo "Version: $version"
cross build --target aarch64-unknown-linux-gnu
echo "Copy $DEB to icy_board.deb"
mkdir bin
mv target/release/icy_board bin
mv target/release/icbsetup bin
mv target/release/icbmailer bin
mv target/release/icbsysmgr bin
mv target/release/mkicbmnu bin
mv target/release/mkicbtxt bin
mv target/release/pplc bin
mv target/release/ppld bin
mv target/release/scandb bin
mv target/release/ppl-language-server bin
- name: 'Upload zip'
uses: actions/upload-artifact@v4
with:
name: icy_board_aarch64_${{ env.VERSION }}
path: |
bin/icy_board
bin/icbsetup
bin/icbmailer
bin/icbsysmgr
bin/mkicbmnu
bin/mkicbtxt
bin/pplc
bin/pppld
bin/scandb
bin/ppl-language-server
file_id.diz
32 changes: 32 additions & 0 deletions INSTALL.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
Just unzip anywhere. IcyBoard works with relative and not absolute paths.


Create a bbs with:

bin/icbsetup create bbs

This creates all required files in "bbs"

Or import an existing pcboard installation with:

bin/icbsetup import [PCBOARD.DAT] bbs

Where PCBOARD.DAT is the pull path to the pcboard data file. Note that the original installation won't be altered at all.
Howver it's not 100% so manual changes are likeley to be required but the output should be a good starting point. I can need test installations for improving the importer.

Then just start with:

bin/icy_board --file bbs

It's recommended to put bin/ in path and just start icy_board etc. inside the bbs directory - it'll be picked up all automatically.

Following tools are currently shipped

icbsetup - setting up with a tui client - in theory the .toml files can be edited with any text editor but it's easier with a tui
icbsysmgr - user/groups edutor.
mkicbtxt - create & alter PCBTEXT files (compatible with old PCBoard format)
mkicbmnu - create & change icy_board .mnu files
pplc - ppl compiler
ppl-language-server - a lsp implementation that can be used in editors that support it to get some syntax coloring, help and code completion for ppl

The other tools are work in progress and will be split up into other commands.
4 changes: 1 addition & 3 deletions crates/icy_board_engine/src/icy_board/state/functions.rs
Original file line number Diff line number Diff line change
Expand Up @@ -247,10 +247,8 @@ impl IcyBoardState {
let old = self.session.disp_options.non_stop;
self.session.disp_options.non_stop = true;
for (i, line) in converted_content.lines().enumerate() {
if i > 0 {
self.write_raw(TerminalTarget::Both, &['\r', '\n']).await?;
}
self.display_line(line).await?;
self.write_raw(TerminalTarget::Both, &['\r', '\n']).await?;
self.session.disp_options.non_stop = false;
let next = self.next_line().await?;
self.session.disp_options.non_stop = true;
Expand Down
2 changes: 1 addition & 1 deletion crates/pplc/src/main.rs
Original file line number Diff line number Diff line change
Expand Up @@ -179,7 +179,7 @@ fn check_errors(errors: std::sync::Arc<std::sync::Mutex<icy_board_engine::parser
// let file_name = file_name.to_string_lossy().to_string();
for err in &errors.lock().unwrap().errors {
error_count += 1;
Report::build(ReportKind::Error, err.span.clone())
Report::build(ReportKind::Error, err.span.clone())
.with_code(error_count)
.with_message(format!("{}", err.error))
.with_label(Label::new(err.span.clone()).with_color(ariadne::Color::Red))
Expand Down
14 changes: 14 additions & 0 deletions crates/qfile/.gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
/target
/Cargo.lock
/Polygon
/.Polygon
/.polygon
/polygon
/.vscode
/src/main.rs
/src/core/unit_tests
/file_root.txt
/.Folder
/.folder
/Folder
/folder
4 changes: 3 additions & 1 deletion tools/prep_diz.py
Original file line number Diff line number Diff line change
Expand Up @@ -21,4 +21,6 @@

f = open(sys.argv[1], "w")
f.writelines(new_lines)
f.close()
f.close()

print(version)

0 comments on commit 483a644

Please sign in to comment.