Skip to content

Commit b40fe94

Browse files
committed
Document Git Large File Storage usage in SWT
And move the general Contributing section further up to improve the README structure.
1 parent 7bf44ae commit b40fe94

2 files changed

Lines changed: 43 additions & 11 deletions

File tree

AGENTS.md

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -23,6 +23,21 @@ SWT consists of two main parts:
2323
- `examples/` - Example code and snippets
2424
- `tests/` - JUnit tests
2525

26+
### Native binaries
27+
28+
This repository uses Git Large File Storage (LFS) to store precompiled native binaries.
29+
The `.gitattributes` file specifies which files are stored using LFS.
30+
31+
If Git LFS is not installed and configured the LFS pointer files are not resolved on checkout and the binaries have to be compiled locally.
32+
For that, see the `Build Commands` section below.
33+
34+
**NOTE**:
35+
For GitHub Copilot agent sessions Git LFS checkout is disabled.
36+
37+
Cross-compiling binaries for operating systems other than the one currently in use is not possible, just as testing code for other platforms is not possible.
38+
If you make changes to code (Java or native) for other platforms, the binaries cannot be rebuilt and the changes cannot be tested locally.
39+
Instead, rely on the GitHub PR workflows created for each platform to test the changes.
40+
2641
## Build System
2742

2843
### Technology Stack
@@ -50,6 +65,8 @@ Instead: modify Java source (e.g., `OS.java`), clean/rebuild the project, then r
5065

5166
See `docs/*.md` and `bundles/org.eclipse.swt/Readme*.md` files for detailed instructions.
5267

68+
Usually only the native binaries of the targeted platform can be built locally.
69+
5370
## Coding Standards
5471

5572
### Java Code

README.md

Lines changed: 26 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -81,6 +81,32 @@ The `while`-loop processes all GUI related events until the shell is disposed wh
8181
Before exiting, any claimed GUI resources needs to be freed.
8282

8383

84+
# Contributing to SWT
85+
86+
Thanks for your interest in this project.
87+
88+
For information about contributing to Eclipse Platform in general, see the general [CONTRIBUTING](https://github.com/eclipse-platform/.github/blob/main/CONTRIBUTING.md) page.
89+
90+
[![Create Eclipse Development Environment for Eclipse SWT](https://download.eclipse.org/oomph/www/setups/svg/SWT.svg)](
91+
https://www.eclipse.org/setups/installer/?url=https://raw.githubusercontent.com/eclipse-platform/eclipse.platform.swt/master/bundles/org.eclipse.swt.tools/Oomph/PlatformSWTConfiguration.setup&show=true
92+
"Click to open Eclipse-Installer Auto Launch or drag into your running installer")
93+
94+
## Obtaining the sources
95+
96+
The SWT source code is stored in this Git repository.
97+
98+
This repository uses the [Git Large File Storage](https://git-lfs.com/) (LFS) extension to host also the precompiled SWT native binaries,
99+
which is therefore required unless binaries are compiled locally.
100+
101+
When using Git from the CLI follow the Git LFS installation and setup instructions:
102+
- https://github.com/git-lfs/git-lfs/wiki/Installation#installing
103+
104+
When using _EGit_ from within Eclipse follow the EGit user guide on _GIT LFS Support_:
105+
- https://github.com/eclipse-egit/egit/wiki/User-Guide#git-lfs-support
106+
107+
Note:<br>
108+
Changes to the binary artifacts must not be committed, as the binaries are compiled only in the Eclipse infrastructure.
109+
84110
## Building
85111

86112
To build all SWT artifacts and to run all tests,
@@ -95,17 +121,6 @@ mvn clean verify -DskipTests
95121

96122
For instructions on building the native binaries of SWT see the section [Building native binaries](bundles/org.eclipse.swt/Readme.md#building-native-binaries).
97123

98-
# Contributing to SWT
99-
100-
Thanks for your interest in this project.
101-
102-
For information about contributing to Eclipse Platform in general, see the general [CONTRIBUTING](https://github.com/eclipse-platform/.github/blob/main/CONTRIBUTING.md) page.
103-
104-
[![Create Eclipse Development Environment for Eclipse SWT](https://download.eclipse.org/oomph/www/setups/svg/SWT.svg)](
105-
https://www.eclipse.org/setups/installer/?url=https://raw.githubusercontent.com/eclipse-platform/eclipse.platform.swt/master/bundles/org.eclipse.swt.tools/Oomph/PlatformSWTConfiguration.setup&show=true
106-
"Click to open Eclipse-Installer Auto Launch or drag into your running installer")
107-
108-
109124
## Developer Resources
110125

111126
See the following description for how to contribute a feature or a bug fix to SWT.

0 commit comments

Comments
 (0)