Git Product home page Git Product logo

invil's Introduction

Hi there ๐Ÿ‘‹

invil's People

Contributors

dependabot[bot] avatar jgabaut avatar

Stargazers

 avatar  avatar  avatar

Watchers

 avatar

invil's Issues

[BUG] Tracking issue for 0.2.x bugs

This issue lists all known 0.2.x bugs.

  • #68
  • #75 (fixed in 0.2.1)
  • #77 (fixed in 0.2.1)
  • #89 (fixed in 0.2.4)

These are bugs, but where first discovered from amboso, hence giving the versions containing them effective parity with amboso until fixed there:

  • #87 (fixed in 0.2.4)

[BUG] Semver keys are being compared as strings

Ever since their introduction, map keys are stored as String and no Ord is implemented to handle the keys being semver values.

This leads to the wrong ordering being used, which notably results in potentially the wrong version being build when running invil build on a project.

To Reproduce

  1. Install invil 0.1.2
  2. Try running invil build on a repo
  3. The version being found as latest may not be the correct one (eg. 0.3.9 is picked over 0.3.13).

Expected behavior
Keys are compared as semver (eg. 0.3.13 is picked over 0.3.9).

  • Version 0.1.2

[FEATURE] Setup cargo tests for stego parsing

Cargo tests for parsing stego.lock as TOML should be added, along with a stego-examples directory to hold at least two examples, one correct and one wrong.

Reference the files used in amboso stego parsing tests: link

Success is expected for good.stego and lock.stego, failure is expected for bad.stego.

Most likely, the grammar expressed by regex in the bash implementation would not align with our expectations and we may need to adjust our examples, while still keeping the main expected format.

See also #2

[FEATURE] Improve autotools handling

With 0.0.8, a naive implementation of autotools prep for do_build() was added.

However, it could be improved.

Steps

  • Check system availability of autoconf and automake
    • Handle autotools availability
    • Handls calls to autoconf and automake needed to generate the Makefile
    • See reference in this PR: link

[FEATURE] Feature freeze on amboso 2.x

Eventually, parity with amboso 2.x should be reached and a --strict flag could be implemented to disable all extension and ensure to run with full compatibility to the bash version.

[BUG] Wrong anvil symlink in project generated with init subcommand

The ./anvil symlink created in handle_init_subcommand() is not working as of 0.2.3.

To Reproduce
Steps to reproduce the behavior:

  1. Run invil init ./new-proj
  2. Try running ./new-proj/anvil
  3. Error since the symlink does not point to ./new-proj/amboso/amboso
  4. ./new-proj/amboso/amboso works as expected

Expected behavior
./anvil links to ./new-proj/amboso/amboso

  • Version <= 0.2.3

[FEATURE] Report filesystem name case collision

A warning for filenames being equal (ignoring case) could be emitted when running on such a platform, in some cases:

  • Test names (all tests are meant to be coupled under the same directory)
  • Maybe, list of files in build_tag dir in Basemode (all files for each dir?)

[FEATURE] Parse stego.lock values

Currently, the stego.lock file is simply printed out when found.

It should be parsed as TOML and the result checked for.

Alternatively, custom parsing logic could be implemented.

The new stego.lock format we're targeting is supported by amboso from version 1.8.0. See reference: Pull request

  • Note: amboso's stego.lock should be compatible with toml for versions >=1.9.6.

Docs for parsing TOML: link

Update

It seems that the reference stego format from amboso is not valid to parse as toml::Table.

An update to the reference format to fix this may be helpful, as I really don't want to miss out on assuming stego is valid for toml::Table.

Update 2

As of amboso 1.9.5, the reference implementation uses a stego.lock which can be successfully parsed as toml::Table.

However, the version keys are getting parsed as dotted keys, ending up with a version = {{{ ... }}} definition where each major version is a key in the first level of the values.

Update 3

As of amboso 1.9.6, the reference implementation allows quoted left-values, so that the semver keys don't get parsed as dotted keys by toml.

See also: #3

[FEATURE] Support test mode

Needed functions for test mode should be implemented.

  • Build tests map from executables in anvil_env.kazoj
    • Exclude non-executable files
    • Exclude and report files ending with .stderr, .stdout
  • Run queried test
    • Check if output changed
    • Overwrite expected output with -b
  • #40

[FEATURE] Support -G flag

Needed functions to support -G <target-dir> <tag> should be implemented.

This flag should output appropriate .c and .h files to the passed target-dir.

[BUG] Any non-subcommand call goes to make

Version 0.2.0 added handle_empty_subcomman(), but since it's handled in main before any other check on the arguments, any invocation with no subcommand falls there and returns early.

Version: 0.2.0

[FEATURE] Graceful handling of repo discovery failure

As of version 0.2.1, a run from a non-repo directory fails with:

[ERROR] Failed git check. Error was: {could not find repository at './'; class=Repository (6); code=NotFound (-3)}
[ERROR] check_passed_args() failed with: "could not find repository at './'; class=Repository (6); code=NotFound (-3)"

This could be changed by better handling the result of our discovery, to have different behaviour when outside the happy path.

[BUG] Version tag table doesn't order the keys as semver

As of 0.1.5, the version tags stored as keys in BTreeMap are not following an Ord based on semver semantics.

This should be taken care of by:

  • Check if keys are valid semver names before inserting them in the map

  • Implement ordering for the BTreeMap, by wrapping the stored String in a Semver

  • Version 0.1.5

[FEATURE] Support amboso base, git runmodes

Needed functions for base and git mode should be implemented.

  • Get needed values from stego.lock. See #2.
  • Set supported tags for current runmode
    • Supported tags for other runmode can be filled at the same time.
  • Check if supported tags can be associated with a directory
  • Check if requested tag supports make
    • At first, we can focus on basic cc calls for single-file mode
    • Later, we can add support for make mode. See #34.
      • Check if requested tag supports automake
      • Handle autotools. See #37.
      • Handle make calls

Reference: amboso_main() from here.

[FEATURE] Support base mode operations

Op flags for base run-mode can be handled to try performing the requested operation for requested tag.

  • Add functions to handle op flags for base mode
    • -r for running
    • -b for building (ATM only basic gcc call is supported)
    • -d to delete
    • -i for building all supported tags (ATM only basic gcc call is supported)
    • -p for deleting all binaries for supported tags

[FEATURE] Improve Gitmode implementation

0.0.7 added a naive implementation for the Gitmode branch in do_build(). See PR.

Using Command for each needed step should be avoided, when a more idiomatic Rust solution can be used instead.

The basic pipeline should be something like:

git checkout <query> && git submodule update --init -recursive && make && mv <bin> <tag_dir> && git switch - && git submodule update --init --recursive

Note

Version 0.1.6 runs make rebuild by default and make when --no-rebuild is passed.

I think there's some git flag we can use to do the checkout and first submodule prep in one command.

Steps

  • Checkout requested tag
  • Init submodules to tag status
  • Run make
  • Move the build binary to build_tag dir
  • Switch back to original HEAD
  • Init submodule to original HEAD status

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.