Skip to content

Commit

Permalink
feat: 0.0.5 Add do_build() (#31)
Browse files Browse the repository at this point in the history
- Change AmbosoEnv maps to BTreeMap
- -b to try building
- Add do_build(), currently very limited:
  - Only the basic gcc call is supported.
- -q to lower verbose level
- -i to try building tags (only for Basemode)
- Refuse -tT when run is missing support
  • Loading branch information
jgabaut authored Dec 2, 2023
1 parent 023ec2e commit 5a228e7
Show file tree
Hide file tree
Showing 8 changed files with 247 additions and 64 deletions.
3 changes: 3 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1 +1,4 @@
/target

#ignore hello_world binary
hello_world
2 changes: 1 addition & 1 deletion Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

3 changes: 1 addition & 2 deletions Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
[package]
name = "invil"
description = "A port of amboso to Rust"
version = "0.0.4"
version = "0.0.5"
edition = "2021"
license = "GPL-3.0-only"
homepage = "https://github.com/jgabaut/invil"
Expand All @@ -10,7 +10,6 @@ documentation = "https://github.com/jgabaut/invil"
readme = "README.md"
exclude = [
".github/**",
"bin/**",
"try-anvil/**",
"CODEOWNERS",
]
Expand Down
16 changes: 9 additions & 7 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
# invil
[![Latest version](https://img.shields.io/crates/v/invil.svg)](https://crates.io/crates/invil)

## A Rust implementation of amboso, a simple build tool wrapping make.

Expand All @@ -13,13 +14,15 @@

This is a Rust implementation of [amboso](https://github.com/jgabaut/amboso), a basic build tool wrapping make and supporting git tags.

It's in a early stage, and there isn't any functionality yet.
It's in a early stage, and there is limited functionality.
Check the next section for support info.

## Supported amboso features <a name = "supported_amboso"></a>

- Basic arguments parsing that complies with the bash implementation
- Same default for amboso directory (`./bin`).
- Parse `stego.lock` with compatible logic to bash implementation
- Base mode: init and build (only with basic command call)

Flags support status:

Expand All @@ -33,18 +36,18 @@
- [ ] Test macro: `-t`
- [ ] Test mode: `-T`
- [ ] Git mode: `-g`
- [ ] Base mode: `-B`
- [ ] Build: `-b`
- [x] Base mode: `-B` (only basic gcc call)
- [x] Build: `-b` (only with -B)
- [ ] Run: `-r`
- [ ] Init: `-i`
- [x] Init: `-i` (only with -B)
- [ ] Delete: `-d`
- [ ] Purge: `-p`
- [x] Help: `-h`
- [ ] Big Help: `-H`
- [x] Version: `-v`
- [x] List tags for current mode: `-l`
- [x] List tags for git/base mode: `-L`
- [ ] Quiet flag: `-q`
- [x] Quiet flag: `-q`
- [ ] CFG flag: `-c`
- [ ] Watch flag: `-w`
- [x] Warranty flag: `-W`
Expand All @@ -64,7 +67,6 @@ Our version was slightly modified to actually make cargo build the release versi

## Todo <a name = "todo"></a>

- Check all runtime values are valid before op checks
- Implement control flow for op checks
- Implement quiet, verbose, silent functionality
- Implement silent functionality
- Improve logging with a custom format
7 changes: 3 additions & 4 deletions bin/stego.lock
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
[build]

source = "main.rs"
bin = "invil"
source = "hello_world.c"
bin = "hello_world"
makevers = "2.0.0"
automakevers = "3.0.0"
tests = "kazoj"
Expand All @@ -13,5 +13,4 @@ errortestsdir = "kulpo"

[versions]

"-0.0.1" = "First release"
"0.0.2" = "Draft"
"-0.0.5" = "First release supporting base mode build. gcc call only"
4 changes: 4 additions & 0 deletions bin/v0.0.5/.gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
#amboso compliant version folder, will ignore everything inside BUT the gitignore, and required files, to keep the clean dir
*
!hello_world.c
!.gitignore
7 changes: 7 additions & 0 deletions bin/v0.0.5/hello_world.c
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
#include <stdio.h>

int main(void) {
printf("Hello, World!\n");
printf("Built using a single gcc call.\n");
return 0;
}
Loading

0 comments on commit 5a228e7

Please sign in to comment.