Skip to content

Commit

Permalink
WHITESPACE
Browse files Browse the repository at this point in the history
  • Loading branch information
falOn-Dev committed Sep 7, 2024
1 parent 02664df commit 65b67c0
Showing 1 changed file with 7 additions and 3 deletions.
10 changes: 7 additions & 3 deletions source/docs/software/advanced-gradlerio/deploy-git-data.rst
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,8 @@ plugins {

In order to generate the file when building the project, add the following block to the bottom of ``build.gradle``.

.. tab-set::
.. tab-set::

.. tab-item:: Java
```groovy
project.compileJava.dependsOn(createVersionFile)
Expand Down Expand Up @@ -50,7 +51,8 @@ The ``srcDir``, ``classPackage``, and ``className`` parameters tell the plugin w

To test this, run a build of your project through the WPILib menu in the top right. Once the code has finished building, there should be a file called ``BuildConstants.java`` in your ``src/main/java`` folder. The following is an example of what this file should look like:

.. tab-set::
.. tab-set::

.. tab-item:: Java
```Java
package frc.robot;
Expand All @@ -71,6 +73,7 @@ To test this, run a build of your project through the WPILib menu in the top rig
private BuildConstants(){}
}
```

.. tab-item:: Kotlin
```kotlin
package frc.robot
Expand All @@ -96,11 +99,12 @@ To test this, run a build of your project through the WPILib menu in the top rig

These files are regenerated every time code is built or deployed, so it isn't necessary to track them with Git. The aptly named [.gitignore](https://git-scm.com/docs/gitignore) file tells Git not to track any listed files and should exist by default in any project generated by the WPILib VS Code extension. Below is the line you should add to ``.gitignore`` to ignore the generated file:

.. tab-set::
.. tab-set::
.. tab-item:: Java
```text
src/main/java/frc/robot/BuildConstants.java
```

.. tab-item:: Kotlin
```text
src/main/java/frc/robot/BuildConstants.kt
Expand Down

0 comments on commit 65b67c0

Please sign in to comment.