Skip to content

Commit a7a08ac

Browse files
Use devbox to manage development environment
1 parent a1c6110 commit a7a08ac

File tree

4 files changed

+62
-2
lines changed

4 files changed

+62
-2
lines changed

.envrc

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
# Automatically sets up your devbox environment whenever you cd into this
2+
# directory via our direnv integration:
3+
4+
eval "$(devbox generate direnv --print-envrc)"
5+
6+
# check out https://www.jetpack.io/devbox/docs/ide_configuration/direnv/
7+
# for more details

CONTRIBUTING.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -55,7 +55,7 @@ You can check more complete and complex diagrams [here](docs/diagrams).
5555

5656
Here we will detail the main steps and things to take into consideration when implementing a new test element, or extending an existing one.
5757

58-
Before doing any coding, consider that the project uses Java 8, maven 3.5, and docker as main dependencies, so make sure that you install them beforehand.
58+
Before doing any coding, consider that the project uses Java 8, maven 3.5, nodejs 18+, pnpm 8+, and docker as main dependencies, so make sure that you install them beforehand. You might also install [devbox](https://www.jetpack.io/devbox/docs/) and [direnv](https://direnv.net/) and then use existing devbox configuration to setup the development environment.
5959

6060
Additionally, the project uses checkstyle for enforcing code consistency and conventions. You can get IDEs settings from [here](https://github.com/google/styleguide), which already matches the code style rules. Using IDEs autoformatting with such configurations should automatically fix most styling issues.
6161

@@ -129,7 +129,7 @@ Additionally, the project uses checkstyle for enforcing code consistency and con
129129
* In MethodCallBuilderTest defined tests you should not use methods for abstracting duplicate logic between tests (nor variables or constants for literals). Code duplication in this case is acceptable and expected.
130130
* Check [DslTestPlanTest](jmeter-java-dsl/src/test/java/us/abstracta/jmeter/javadsl/core/DslTestPlanTest.java) for some tests examples.
131131
8. Run `mvn clean package` and fix any potential code styling issues or failing tests.
132-
9. Add a new section [user guide](docs/guide), by adding a new md file and proper `@include` in parent section, describing the new feature. Consider running in the `docs` directory `yarn install` and `yarn dev` (this requires node 14 and yarn installed on your machine) to run a local server for docs, where you can review that new changes are properly showing.
132+
9. Add a new section [user guide](docs/guide), by adding a new md file and proper `@include` in parent section, describing the new feature. Consider running in the `docs` directory `pnpm install` and `pnpm dev` (this requires node 18+ and pnpm installed on your machine) to run a local server for docs, where you can review that new changes are properly showing. If you use devbox then you can use `devbox run setup` and `devbox run docs`.
133133
10. Commit changes to git, using as a comment a subject line that describes general changes, and if necessary, some additional details describing the reason why the change is necessary.
134134
11. Submit a pull request to the repository including a meaningful name.
135135
12. Check GitHub Actions execution to verify that no test fails on the CI pipeline.

devbox.json

Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,24 @@
1+
{
2+
"packages": [
3+
"maven@latest",
4+
"nodejs@latest",
5+
"nodePackages.pnpm@latest",
6+
"temurin-bin-8@latest"
7+
],
8+
"shell": {
9+
"init_hook": [
10+
"echo 'Welcome to devbox!' > /dev/null"
11+
],
12+
"scripts": {
13+
"docs": [
14+
"pnpm --dir docs dev"
15+
],
16+
"install": [
17+
"mvn clean install"
18+
],
19+
"setup": [
20+
"pnpm --dir docs install"
21+
]
22+
}
23+
}
24+
}

devbox.lock

Lines changed: 29 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,29 @@
1+
{
2+
"lockfile_version": "1",
3+
"packages": {
4+
"maven@latest": {
5+
"last_modified": "2023-09-10T10:53:27Z",
6+
"resolved": "github:NixOS/nixpkgs/78058d810644f5ed276804ce7ea9e82d92bee293#maven",
7+
"source": "devbox-search",
8+
"version": "3.9.4"
9+
},
10+
"nodePackages.pnpm@latest": {
11+
"last_modified": "2023-09-10T10:53:27Z",
12+
"resolved": "github:NixOS/nixpkgs/78058d810644f5ed276804ce7ea9e82d92bee293#nodePackages.pnpm",
13+
"source": "devbox-search",
14+
"version": "8.6.12"
15+
},
16+
"nodejs@latest": {
17+
"last_modified": "2023-09-10T10:53:27Z",
18+
"resolved": "github:NixOS/nixpkgs/78058d810644f5ed276804ce7ea9e82d92bee293#nodejs_20",
19+
"source": "devbox-search",
20+
"version": "20.6.1"
21+
},
22+
"temurin-bin-8@latest": {
23+
"last_modified": "2023-09-10T10:53:27Z",
24+
"resolved": "github:NixOS/nixpkgs/78058d810644f5ed276804ce7ea9e82d92bee293#temurin-bin-8",
25+
"source": "devbox-search",
26+
"version": "8.0.372"
27+
}
28+
}
29+
}

0 commit comments

Comments
 (0)