https://github.com/seqan/app-template
This template comes pre-configured with various SeqAn libraries and a basic Continuous Integration setup. It is designed to provide a robust starting point for your projects, while offering the flexibility to customize and adapt to your specific requirements.
https://github.com/seqan/app-template
Last synced: 8 months ago
JSON representation
This template comes pre-configured with various SeqAn libraries and a basic Continuous Integration setup. It is designed to provide a robust starting point for your projects, while offering the flexibility to customize and adapt to your specific requirements.
- Host: GitHub
- URL: https://github.com/seqan/app-template
- Owner: seqan
- License: other
- Created: 2020-01-28T13:52:34.000Z (over 6 years ago)
- Default Branch: main
- Last Pushed: 2025-10-07T12:12:15.000Z (9 months ago)
- Last Synced: 2025-10-07T14:14:49.975Z (9 months ago)
- Language: CMake
- Homepage:
- Size: 32.9 MB
- Stars: 6
- Watchers: 8
- Forks: 9
- Open Issues: 20
-
Metadata Files:
- Readme: README.md
- License: LICENSE.md
Awesome Lists containing this project
README
# SeqAn App Template [![build status][1]][2] [![codecov][3]][4]
[1]: https://img.shields.io/github/actions/workflow/status/seqan/app-template/ci_linux.yml?branch=main&style=flat&logo=github&label=App-Template%20CI "Open GitHub actions page"
[2]: https://github.com/seqan/app-template/actions?query=branch%3Amain
[3]: https://codecov.io/gh/seqan/app-template/branch/main/graph/badge.svg "Open Codecov page"
[4]: https://codecov.io/gh/seqan/app-template
This is a template for C++ app developers.
You can easily use this template and modify the existing code to suit your needs.
It provides an elementary CMake set-up, some useful SeqAn libraries, and an example application.
For requirements, check the [Software section of the SeqAn3 Quick Setup](https://docs.seqan.de/seqan3/main_user/setup.html#autotoc_md109).
## Instructions for App Developers:
If you want to build an app, do the following:
0. You need to be signed in with a **GitHub account**.
1. Press the `Use this template`-Button to create your own repository. See [GitHub's documentation](https://docs.github.com/en/github/creating-cloning-and-archiving-repositories/creating-a-repository-from-a-template) for more information.
2. **Wait** for GitHub actions to create a commit in your new repository. The commit message will be `Initialise repository` and it will replace placeholders in the code. Afterwards, the README in your repository will be customised to your repository, among other things.
---
### :warning: Important :warning:
From here on out, follow the instructions in your repository.
You will probably need to reload your repository page to see the changes.
The instructions below are for the template repository and will not work for your repository.
---
3. **Clone** your repository locally: `git clone git@github.com:seqan/app-template.git`
4. Build and test the app (example)
In your local repository clone, you can do the following to build and test your app:
```bash
mkdir build # create build directory
cd build # step into build directory
cmake .. # call cmake on the repository
make # build the app app-template
make check # build and run tests
./bin/app-template # Execute the app (prints a short help page)
```
## Setting up Codecov (optional)
1. Go to https://codecov.io/gh/seqan/app-template.
2. Sign in with your GitHub account.
3. Go to https://app.codecov.io/gh/seqan/app-template/config/general.
If the repository cannot be found, go to https://app.codecov.io/gh/seqan and click `Resync`.
Then try again.
4. Copy the `Repository Upload Token`.
5. Go to https://github.com/seqan/app-template/settings/secrets/actions.
6. Add a `New repository secret` with the name `CODECOV_TOKEN` and the value of the `Repository Upload Token`.
7. Done! The next push to your repository will create a Codecov report.
## Setting up permissions for Lint action (optional)
1. Go to https://github.com/seqan/app-template/settings/actions.
2. Under `Workflow permissions`, at the very bottom, tick `Allow GitHub Actions to create and approve pull requests` and click `Save`.
3. You can go to https://github.com/seqan/app-template/actions/workflows/lint.yml and click `Run workflow` to run linting.
## Instructions for SeqAn3 Tutorial Purposes:
If you just some quick hands-on experience with SeqAn Libraries, you can also just clone this repository and start editing the `src/main.cpp` file.
### Adding a new cpp file
If you want to add a new cpp file (e.g., `tutorial1.cpp`) that is compiled and linked with the current infrastructure, do the following:
1. Create a new file `tutorial1.cpp` in the `src/` directory.
The file content could look like this:
```cpp
#include
int main()
{
seqan3::debug_stream << "Hello, World!" << std::endl;
}
```
2. Add the following lines at the bottom of `src/CMakeLists.txt`
```cmake
# Add another cpp file.
add_executable (tutorial01 tutorial01.cpp)
target_link_libraries (tutorial01 PRIVATE "${PROJECT_NAME}_lib")
```
3. Go to the build directory `cd build`
4. Refresh CMake `cmake .`
5. Build your new cpp file `make tutorial01`
6. Execute your new binary with `./tutorial01`