Skip to content

Commit

Permalink
add a header to be included in each file
Browse files Browse the repository at this point in the history
im feeling like RDC's first line might be treated as shebang like
  • Loading branch information
b1ek committed May 25, 2024
1 parent 841e6a4 commit 2ff9022
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/compiler.rs
Original file line number Diff line number Diff line change
Expand Up @@ -111,7 +111,8 @@ impl AmberCompiler {
result.push(block.translate(&mut meta));
let res = result.join("\n");
format!(
"{}\n{}",
"{}\n{}\n{}",
include_str!("header.sh"),
rdc::generate(meta.externs),
res
)
Expand Down
2 changes: 2 additions & 0 deletions src/header.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
#!/bin/bash
# Written in [Amber](https://amber-lang.com/)

0 comments on commit 2ff9022

Please sign in to comment.