Skip to content

Commit 529f193

Browse files
alehander92zah
authored andcommitted
docs: fixes for the guide, add CONTRIBUTING.md: addressing Stan's review comments
1 parent e454c9a commit 529f193

File tree

14 files changed

+97
-41
lines changed

14 files changed

+97
-41
lines changed

CONTRIBUTING.md

Lines changed: 35 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,35 @@
1+
<!-- copied as both top-level codetracer repo CONTRIBUTING.md and a contributing page in the docs book -->
2+
3+
## Contributing
4+
5+
We welcome contributors!
6+
7+
If you want to fix something smaller, feel free to open an issue or a a PR.
8+
9+
For bigger changes it's advised to first open an issue/discussion in the relevant Github repo or to discuss it our team in our [Discord chat server](https://discord.gg/aH5WTMnKHT).
10+
11+
### Contributors guide
12+
13+
Here are some recommendations, however if you want more info, our docs/contributor guide are hosted [on the CodeTracer site](https://contributors-guide.codetracer.com/) !
14+
15+
The guide is written as a set of markdown documents and built using [mdbook](https://rust-lang.github.io/mdBook/) and [mdbook-alerts](https://crates.io/crates/mdbook-alerts) .
16+
17+
You can contribute to the documentation itself, by editing it in `docs/book` and making a pull request. You can iterate on it locally , by cloning the repo, activating it's nix devshell and running `just serve-docs [hostname port]`: it will serve it locally(by default on http://localhost:3000).
18+
19+
### Style guide
20+
21+
For Rust, we are using `cargo fmt` to autoformat our code, and `cargo clippy` with some custom allow/deny rules inside the code.
22+
We have a `cargo clippy` check in our CI, but one can also run it locally.
23+
24+
For Nim, we still haven't written down a guide or list of rules and principles that we agree on, so this is something that we hope to do.
25+
We might also link to an existing document.
26+
27+
### Commits/Pull Requests
28+
29+
We are using [the "Conventional Commits" strategy](https://www.conventionalcommits.org/).
30+
31+
We use or are ok with using more "types", not only those included by default in their official page: e.g. `cleanup:`, `tooling:`, `examples:` etc.
32+
33+
We use `git rebase`, not merge and currently use the github pull requests as the main way to add code. Any pull request would need at least one review
34+
from someone from the CodeTracer team.
35+

docs/book/book.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
[book]
2-
authors = ["Stanislav Vasilev"]
2+
authors = ["CodeTracer team"]
33
language = "en"
44
multilingual = false
55
src = "src"

docs/book/src/CONTRIBUTING.md

Lines changed: 35 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,35 @@
1+
<!-- copied as both top-level codetracer repo CONTRIBUTING.md and a contributing page in the docs book -->
2+
3+
## Contributing
4+
5+
We welcome contributors!
6+
7+
If you want to fix something smaller, feel free to open an issue or a a PR.
8+
9+
For bigger changes it's advised to first open an issue/discussion in the relevant Github repo or to discuss it our team in our [Discord chat server](https://discord.gg/aH5WTMnKHT).
10+
11+
### Contributors guide
12+
13+
Here are some recommendations, however if you want more info, our docs/contributor guide are hosted [on the CodeTracer site](https://contributors-guide.codetracer.com/) !
14+
15+
The guide is written as a set of markdown documents and built using [mdbook](https://rust-lang.github.io/mdBook/) and [mdbook-alerts](https://crates.io/crates/mdbook-alerts) .
16+
17+
You can contribute to the documentation itself, by editing it in `docs/book` and making a pull request. You can iterate on it locally , by cloning the repo, activating it's nix devshell and running `just serve-docs [hostname port]`: it will serve it locally(by default on http://localhost:3000).
18+
19+
### Style guide
20+
21+
For Rust, we are using `cargo fmt` to autoformat our code, and `cargo clippy` with some custom allow/deny rules inside the code.
22+
We have a `cargo clippy` check in our CI, but one can also run it locally.
23+
24+
For Nim, we still haven't written down a guide or list of rules and principles that we agree on, so this is something that we hope to do.
25+
We might also link to an existing document.
26+
27+
### Commits/Pull Requests
28+
29+
We are using [the "Conventional Commits" strategy](https://www.conventionalcommits.org/).
30+
31+
We use or are ok with using more "types", not only those included by default in their official page: e.g. `cleanup:`, `tooling:`, `examples:` etc.
32+
33+
We use `git rebase`, not merge and currently use the github pull requests as the main way to add code. Any pull request would need at least one review
34+
from someone from the CodeTracer team.
35+

docs/book/src/SUMMARY.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
## Summary
22

33
- [Introduction](./introduction.md)
4-
- [Contributions](./contributions.md)
4+
- [Contributing](./CONTRIBUTING.md)
55

66
## Usage guide
77

docs/book/src/backends/db-backend/py.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
## python
1+
## Python language
22

33
We currently have started adding support for recording python programs for the DB backend, but the prototype isn't finished yet.
44

docs/book/src/backends/db-backend/ruby.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,5 +5,5 @@ We support many cases, you can use it like `ct record <path to rb file> [<args>]
55

66
The recorder for Ruby is currently hosted in the [codetracer-ruby-recorder](https://github.com/metacraft-labs/codetracer-ruby-recorder) repo.
77

8-
You can read its README for more details. We are welcoming contributors!
8+
You can read its README for more details. We welcome contributors!
99

docs/book/src/backends/db_backend.md

Lines changed: 9 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,7 @@
11
## DB backend
22

3+
### Languages
4+
35
The DB backend is currently used for interpreted languages, like scripting and blockchain/zero knowledge languages:
46

57
1. [Noir](./db-backend/noir.md)
@@ -8,14 +10,18 @@ The DB backend is currently used for interpreted languages, like scripting and b
810
1. [Lua(not done: just a plan)](./db-backend/lua.md)
911
1. [small(a toy interpreter for dogfooding)](./db-backend/small.md)
1012

11-
If you're interested in db-backend support for those languages or for now ones, you can discuss with us on our Github issue tracker,
12-
in the discussions or in our [chat server](https://discord.gg/aH5WTMnKHT). We welcome contributors!
13+
If you're interested in db-backend support for those languages or for now ones, you can discuss with us on our [GitHub issue tracker](https://github.com/metacraft-labs/codetracer/issues),
14+
in the [GitHub repo discussions forum](https://github.com/metacraft-labs/codetracer/discussions) or in our [discord chat server](https://discord.gg/aH5WTMnKHT). We welcome contributors!
15+
16+
### Additional directions
1317

14-
However it might be used for emulators(and this way for native languages) in the future.
18+
However we're exploring using this method for emulators(and conversely, for emulating native languages) in the future.
1519

1620
Also, languages can have both native(AOT) and interpreted implementations:
1721
so we can more easily support e.g. interpreters/VM-s of certain languages with this backend currently.
1822

23+
### Implementation
24+
1925
As the name suggests, this backend is implemented as a database. Due to its properties, this backend provides
2026
a more complete feature set - one of the reasons it was ready first.
2127

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
11
# Go
22

33
We have developed а basic integration that supports small parts of the Golang language in the Core backend.
4-
Development on a more complete revision is scheduled to start soon!
4+
Development of a more complete revision is scheduled to start soon!

docs/book/src/backends/rr_backend.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ preloading information, such as the information, needed for omniscience and call
1717
currently implemented using python code using the gdb API.
1818
(If required, this can be changed to use the lldb API or something more custom, like a dwarf lib-based solution. We are currently using the rust `gimli` DWARF lib for a tool, that helps with recording/metadata in the RR backend).
1919

20-
These are the main differences, when compared to the DB Backend: based on the way RR works:
20+
These are the main differences, when compared to the DB Backend, based on the way RR works:
2121

2222
1. Only non-deterministic events are recorded.
2323
1. The program's different states are navigated through re-execution.

docs/book/src/building_and_packaging/build_systems.md

Lines changed: 7 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -3,14 +3,16 @@
33
Codetracer uses nix, just, tup and direnv as parts of its build system.
44

55
## Breakdown of the different components
6+
67
### Nix
7-
The Nix package manager/build system deals with managing all dependencies, required by CodeTracer, as well as packaging
8+
9+
The [Nix](https://nixos.org/) package manager/build system deals with managing all dependencies, required by CodeTracer, as well as packaging
810
it for NixOS. It can package for other operating systems through an AppImage generator utility, however currently we are building our
911
appimages with custom shell scripts in `appimage-scripts`.
1012

1113
### Just
1214

13-
The `just` tool is used to trigger build commands and various other actions. It's semi-analogous to a Makefile. The following commands are
15+
The [just](https://just.systems/) task runner is used to trigger build commands and various other actions. It's semi-analogous to a Makefile. The following commands are
1416
the most widely-used:
1517

1618
1. `just build` - Builds the project with Tup and starts the automatic build process, which is used for active development
@@ -25,10 +27,11 @@ the most widely-used:
2527
1. `just reset-config` - Resets the user's configuration if it's incompatible with the latest version of CodeTracer. Further [documentation](https://dev-docs.codetracer.com/Introduction/Configuration)
2628

2729
### Tup
28-
The Tup build system is used for local builds of CodeTracer and deals with calling the actual low-level build instructions.
30+
31+
The [Tup](https://gittup.org/tup/) build system is used for local builds of CodeTracer and deals with calling the actual low-level build instructions.
2932

3033
### Direnv
31-
The `direnv` utility sets up your local environment for using CodeTracer.
34+
The [direnv](https://direnv.net/) utility sets up your local environment for using CodeTracer.
3235

3336
## Packaging
3437

0 commit comments

Comments
 (0)