Add basic project scaffolding functionality via CLI#78
Draft
wenkanglu wants to merge 6 commits intotinymanorg:mainfrom
Draft
Add basic project scaffolding functionality via CLI#78wenkanglu wants to merge 6 commits intotinymanorg:mainfrom
wenkanglu wants to merge 6 commits intotinymanorg:mainfrom
Conversation
Collaborator
|
This looks really interesting! I haven't gone through in detail yet but really like the general idea. Thank you :) |
Passing a directory to _build() now builds all Tealish files in the tree. The structure of the build output retains the same tree shape as the build target. Build can now also be called from any directory within the project.
|
Thoughtful suggestions! Generally good and can be implemented to ease our understanding of how to meet/achieve goals! |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Just a simple WIP of scaffolding a new Tealish project with a template smart contract, test, and basic utility functions. This is achieved through a new CLI command called
start(not entirely sold on the name but it's a start 😉).As part of the scaffold, there is a
tealish.jsonfile at the root level that contains configs. For now there is only a config for the name (and location) of the build directory that the_build()function builds to. If the config does not exist, the standard name and location is used (build directory at the location of the Tealish file).Example Usage
tealish start my_tealish_project --template=algosdk.cdinto the project root directory.tealish compile contractspython3 -m unittest(assumes algod, kmd, and indexer are running on default Sandbox ports)Thoughts
start.startshould be enforced, e.g., build, contracts, tests directories, and config file all at root level. This makes it easier to reason about the location of certain files when creating new CLI features. However, the names of each directory should be configurable via the config file (like with the build directory).requirements.txtin the scaffold for the sake of simplicity but we can of course choose to supportpyproject.tomlinstead.