Commit graph

18 commits

Author SHA1 Message Date
IGI-111
3efc60e22b
Bump to v0.43.0 (#4897) 2023-08-02 22:57:10 +02:00
Brandon Kite
67b37ce4cc
Fuel Core v0.17.0 Upgrade (#3961) 2023-02-08 20:01:12 +11:00
Mitchell Mackert
4eb4edd17a
Update sway book README (#3983)
Closes #3981

---------

Co-authored-by: Joshua Batty <joshpbatty@gmail.com>
2023-02-07 10:34:49 +11:00
Nick Furfaro
ed1bc39c67
Run cargo clippy --fix in the sway repo (#3903)
Co-authored-by: Sophie <sophiedankel@gmail.com>
2023-01-26 16:05:13 -05:00
bing
567ac2e14f
forc documenter refactor (#3182) 2022-10-31 05:53:13 -04:00
mitchmindtree
dab1c74b2a
Remove Rust integration testing behaviour from forc test in anticipation of unit testing support (#2264)
This PR is a WIP that aims to address the first 3 steps in #1833.

This is in anticipation of using `forc test` to support unit testing
(rather than Rust integration testing) #1832.

The `forc test` command remains for now, but outputs a message
explaining that the command is now reserved for unit testing and links
to the issues above.

## TODO

- [x] Create a new `sway-test-rs` repo or similar that can be used as a
`cargo generate` template.
- [x] Update Rust integration testing docs in the Sway book to describe
how to use the `cargo generate` command to easily add Sway integration
testing to an existing Rust project.

## Follow-up

- Create a `forc-test-rs` crate that re-exports and extends `fuels` with
useful `forc` functionality for integration testing (e.g. re-exporting
`forc_pkg::build` to ensure sway code is built and available under
`out/` at the start of testing).
2022-10-10 12:27:13 +11:00
Kaya Gökalp
1ed1cf1fa0
Split client interaction commands into a forc-client plugin (#2440) 2022-08-18 01:46:12 +00:00
John Adler
fddb2067dd
Create markdown-lint.yml (#2534)
* Create markdown-lint.yml

* Fix lint errors.
2022-08-15 12:45:07 -04:00
Kaya Gökalp
87e0a488cf
Fix new clippy lints (with rust version 1.63) (#2518) 2022-08-11 19:13:33 +00:00
bing
3b87465c0f
Deprecate forc gm (#2382)
* remove forc-gm dir

* remove forc-gm from workspace

* Update 'forc gm' reference in tests to 'forc explore'
2022-07-27 00:57:05 +08:00
John Adler
9dc04fca7f
Fix and clean up forc reference docs. (#2233)
* Fix and clean up forc reference docs.

* Revert path surround change.

* Surround with backticks.
2022-07-06 00:49:00 +00:00
rashad
fd3a96f13b
Distinguish between forc init and forc new (Copy over changes from PR#1669) (#2175)
* Copy over changes from PR#1669

* Rework `forc new` in terms of `forc init`

This removes all of the duplicated logic from the `forc new` command in
favour of re-using the `forc init` op.

* Add missing doc

* Add missing comment

Co-authored-by: Rashad Alston <rashad@Rashads-MacBook-Pro.local>
Co-authored-by: mitchmindtree <mitchell.nordine@fuel.sh>
Co-authored-by: Rashad Alston <rashad@Rashads-MBP.attlocal.net>
2022-07-01 10:09:07 -07:00
bing
3de2557657
preprocessor strictness change (#1987)
* add toml dependency

* add check for 'strict' env var

* update CI with env var

* Update READMEs

* Wording
2022-06-15 10:59:48 +00:00
bing
4fab68f9ee
update README related to Forc commands/plugins (#1728)
* Add instructions to update mdbook-forc-documenter if 'Commands' or 'Plugins' chapter names change

* replace forc gm example with forc explore, and add 'or plugin' after every reference to command

* Add instructions to add plugin installation within CI

* newline

* more info on taking action

* consistent wording

* Clearer wording on removing plugin

* fix: behaviour -> behavior

* Use permalinks

* use permalink in docs/README.d as well
2022-05-27 13:19:01 -04:00
Kaya Gökalp
53361ee726
forc template implementation (#1614)
* forc template resolves the HEAD and fetches the repo. Prints the requested directorie's path

* forc template works with and without template name

* forc init --template removed, pkg.rs unused pub modifier removed

* extra info added before copy, cargo-toml-lint, udeps fix, mdbook fix

* invoke CI

* Update scripts/mdbook-forc-documenter/examples/forc_template.md

Co-authored-by: John Adler <adlerjohn@users.noreply.github.com>

* Update scripts/mdbook-forc-documenter/examples/forc_template.md

Co-authored-by: John Adler <adlerjohn@users.noreply.github.com>

* default url provided, project_name is last parameter to pass without --project_name

* cargo fmt

* println to tracing::info

* local_repo_name to template_name

Co-authored-by: John Adler <adlerjohn@users.noreply.github.com>
2022-05-24 02:47:41 +03:00
bing
17b9e24730
document native plugins within the Sway book (#1582)
* Refactoring to get ready for plugin documentation integration

* Check for errors when updating doucmentation

* Fix formatting of error text

* Remove unused BorrowMut

* Add plugin docs

* strip whitespace to remove version no. from plugin command header

* Better naming for commands/plugins within preprocessor

* extract inject_content

* handle parsing subcommand

* Refactor

* Install plugins within ci and gh-pages

* order plugins alphabetically

* official_plugin_commands -> plugin_commands, since they mean the same

* Handle error messages better

* subcommand_is_parsed -> has_parsed_subcommand_header for consistency

* More consistent expect message

* Add additional white spaces for test_format_subcommand_line

* cargo install --debug to speed things up

* Update input from &Vec<String> to &[String]

* Move forc-explore, forc-fmt, forc-lsp, into forc-plugins dir

* Update CI ymls with new plugins path

* Update all references to forc plugins in ci

* Programatically get plugins from forc-plugins

* Update ci.yml

* Properly install plugins

* Re-add removed cancel-previous-run

* Remove unused actions-rs/cargo

* Update plugins installation for gh-pages.yml

* Improve plugins.rs

* Improved find_forc_plugins_dir

* Remove return line within format_header_line

* Fix bug where preprocessor would panic if not in Sway root (#1618)

While testing, I noticed that the build would panic if you attempted to
`mdbook build` the book while in the `docs` directory. I then realised
we had a misuse of the `current_dir` function which must have slipped
through in a previous PR review. I've fixed this by adding a
`find_sway_repo_root` fn and implementing functions to find the plugins
and examples directories in terms of it.

Co-authored-by: mitchmindtree <mitchell.nordine@fuel.sh>
2022-05-23 11:12:53 +08:00
Kaya Gökalp
1cf7696e5e
Transition to tracing in forc (and throughout sway) over println (#1575) 2022-05-20 11:18:01 +03:00
bing
e75cbd7c97
Use forc-documenter as an mdbook preprocessor instead (#1545)
* mdbook-forc-documenter

* Cargo.toml update

* Delete forc documenter script folder

* Introduce mdbook-forc-documenter

* Update CI

* Cargo.lock

* make clippy happy

* Remove println

* Add examples in .md format

* Load examples

* Make clippy happy

* Delete forc_completions

* Re-add forc_completions

* Reorder cargo.toml dependencies

* Add README for mdbook-forc-documenter

* Update book README

* Update make_app

* Revert ci.yml

* Remove forc-documenter-dry-run from ci.yml

* Add mechanism to detect inconsistencies between forc commands and documentation

* Handle removed commands and new commands separately

* make clippy happy :)

* Fix errors in Cargo.toml

* typo: competions -> completions

* Remove redundant \n

* Update Cargo.toml

* Update Cargo.lock
2022-05-17 15:02:28 +08:00