Skip to content

Commit 76e9bec

Browse files
authored
Merge pull request #1 from nav-solutions/develop
ionex v0.1.0
2 parents 5635a29 + 22abe23 commit 76e9bec

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

50 files changed

+5912
-2
lines changed

.github/ISSUE_TEMPLATE.md

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
## Issue reporting
2+
3+
Thank you for using our library and trying to make it better 🛰️ 🌍
4+
5+
## Error reporting
6+
7+
When reporting an issue related to one of our libraries, an error log will suffice.
8+
9+
If your post-processing pipeline is complex and involves very specific data, it may be required
10+
that you provide your input data so we can replicate the problem. To do so, contact us
11+
through one of our portals and we have means to arrange that. If you are willing to do so,
12+
you can directly submit your test data into our [dedicated repo](https://github.com/nav-solutions/data)
13+
and we can start replicating the issue right away.

.github/dependabot.yml

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
version: 2
2+
updates:
3+
- package-ecosystem: cargo
4+
directory: "/"
5+
schedule:
6+
interval: daily
7+
time: "12:00"
8+
open-pull-requests-limit: 10

.github/workflows/benchmarks.yml

Lines changed: 45 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,45 @@
1+
name: Benchmarking
2+
3+
on:
4+
push:
5+
branches:
6+
- main
7+
tags:
8+
- "*"
9+
pull_request:
10+
workflow_dispatch:
11+
12+
jobs:
13+
benchmarking:
14+
name: Benchmarking (API)
15+
runs-on: ubuntu-latest
16+
env:
17+
CARGO: cargo
18+
RUST_BACKTRACE: 1
19+
strategy:
20+
fail-fast: false
21+
matrix:
22+
include:
23+
- bench: parsing
24+
sample_size: 1000
25+
- bench: formatting
26+
sample_size: 1000
27+
28+
steps:
29+
- name: Checkout sources
30+
uses: actions/checkout@v4
31+
with:
32+
submodules: recursive
33+
fetch-depth: 0
34+
35+
- name: Install Rust
36+
uses: dtolnay/rust-toolchain@master
37+
with:
38+
toolchain: 1.82.0
39+
override: true
40+
41+
- name: Bench
42+
run: cargo bench --all-features --bench ${{ matrix.bench }} -- --sample-size ${{ matrix.sample_size }} > ${{ matrix.bench }}.txt
43+
44+
- name: Upload Results
45+
run: python tools/parse_crit_benchmark.py < ${{ matrix.bench }}.txt >> $GITHUB_STEP_SUMMARY

.github/workflows/daily.yml

Lines changed: 62 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,62 @@
1+
name: Daily
2+
3+
on:
4+
workflow_dispatch:
5+
schedule:
6+
- cron: "0 0 * * *" # midnight, every day
7+
8+
env:
9+
RUST_BACKTRACE: 1
10+
CARGO_TERM_COLOR: always
11+
12+
jobs:
13+
build:
14+
name: Build
15+
runs-on: ubuntu-latest
16+
steps:
17+
- uses: actions/checkout@v3
18+
with:
19+
submodules: recursive
20+
fetch-depth: 0
21+
22+
- uses: actions-rs/toolchain@v1
23+
name: Install Rust
24+
with:
25+
toolchain: 1.82.0
26+
override: true
27+
28+
- uses: actions-rs/cargo@v1
29+
name: Build (default)
30+
with:
31+
command: build
32+
33+
- uses: actions-rs/cargo@v1
34+
name: Build (all features)
35+
with:
36+
command: build
37+
args: --all-features
38+
39+
- uses: actions-rs/cargo@v1
40+
name: Test (all features)
41+
with:
42+
command: test
43+
args: --all-features
44+
45+
documentation:
46+
name: Documentation
47+
runs-on: ubuntu-latest
48+
steps:
49+
- uses: actions/checkout@v3
50+
with:
51+
submodules: recursive
52+
fetch-depth: 0
53+
54+
- uses: actions-rs/toolchain@v1
55+
name: Install nightly
56+
with:
57+
toolchain: nightly
58+
override: true
59+
60+
- name: Documentation
61+
run: |
62+
./tools/builddoc.sh

.github/workflows/release.yml

Lines changed: 45 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,45 @@
1+
name: Release
2+
3+
on:
4+
push:
5+
tags:
6+
- '*'
7+
8+
permissions:
9+
contents: write
10+
11+
jobs:
12+
publish:
13+
name: Publish
14+
runs-on: ubuntu-latest
15+
continue-on-error: true
16+
if: github.ref_type == 'tag'
17+
steps:
18+
- name: Checkout
19+
uses: actions/checkout@v4
20+
21+
- name: Install stable
22+
uses: actions-rs/toolchain@v1
23+
with:
24+
toolchain: stable
25+
26+
- name: Publish
27+
env:
28+
TOKEN: ${{ secrets.CRATES_IO_TOKEN }}
29+
run: |
30+
cargo login $TOKEN
31+
cargo publish
32+
33+
release:
34+
runs-on: ubuntu-latest
35+
needs: ['publish']
36+
steps:
37+
- name: Create Release
38+
id: create_release
39+
env:
40+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
41+
uses: actions/create-release@v1
42+
with:
43+
draft: true
44+
tag_name: ${{ github.ref_name }}
45+
release_name: ${{ github.ref_name }}

.github/workflows/rust.yml

Lines changed: 74 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,74 @@
1+
name: CI
2+
3+
on:
4+
push:
5+
branches:
6+
- main
7+
tags:
8+
- "*"
9+
pull_request:
10+
branches:
11+
- main
12+
13+
env:
14+
RUST_BACKTRACE: 1
15+
CARGO_TERM_COLOR: always
16+
17+
jobs:
18+
build:
19+
name: Build
20+
runs-on: ubuntu-latest
21+
steps:
22+
- uses: actions/checkout@v3
23+
with:
24+
submodules: recursive
25+
fetch-depth: 0
26+
27+
- uses: actions-rs/cargo@v1
28+
name: Linter
29+
with:
30+
command: fmt
31+
args: --all -- --check
32+
33+
- uses: actions-rs/toolchain@v1
34+
name: Install Rust
35+
with:
36+
toolchain: 1.82.0
37+
override: true
38+
39+
- uses: actions-rs/cargo@v1
40+
name: Build (default)
41+
with:
42+
command: build
43+
args: -r
44+
45+
- uses: actions-rs/cargo@v1
46+
name: Build (all features)
47+
with:
48+
command: build
49+
args: --all-features
50+
51+
- uses: actions-rs/cargo@v1
52+
name: Tests
53+
with:
54+
command: test
55+
args: --all-features
56+
57+
documentation:
58+
name: Documentation
59+
runs-on: ubuntu-latest
60+
steps:
61+
- uses: actions/checkout@v3
62+
with:
63+
submodules: recursive
64+
fetch-depth: 0
65+
66+
- uses: actions-rs/toolchain@v1
67+
name: Install nightly
68+
with:
69+
toolchain: nightly
70+
override: true
71+
72+
- name: Documentation
73+
run: |
74+
./tools/builddoc.sh

.gitignore

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,9 @@
33
debug
44
target
55

6+
*.lock
7+
*.rs~
8+
69
# These are backup files generated by rustfmt
710
**/*.rs.bk
811

@@ -19,3 +22,13 @@ target
1922
# and can be added to the global gitignore or merged into this file. For a more nuclear
2023
# option (not recommended) you can uncomment the following to ignore the entire idea folder.
2124
#.idea/
25+
26+
*.swo
27+
*.swp
28+
29+
ckmg-v1.txt
30+
jplg-v1.txt
31+
custom.txt
32+
region.txt
33+
test.txt
34+
test.txt.gz

.gitmodules

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
[submodule "data"]
2+
path = data
3+
url = git@github.com:nav-solutions/data.git
4+
[submodule "tools"]
5+
path = tools
6+
url = git@github.com:nav-solutions/tools.git

CONTRIBUTING.md

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
CONTRIBUTING
2+
============
3+
4+
Hello and welcome onboard :wave:
5+
6+
Use the github portal to submit PR, all contributions are welcomed.
7+
Don't forget to run a quick `cargo fmt` prior any submissions, so the CI/CD does not fail
8+
on coding style "issues".
9+
10+
You can contact us on [Discord](https://discord.com/invite/VwuKPcw6)

Cargo.toml

Lines changed: 58 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,58 @@
1+
[package]
2+
name = "ionex"
3+
version = "0.1.0"
4+
license = "MPL-2.0"
5+
authors = ["Guillaume W. Bres <guillaume.bressaix@gmail.com>"]
6+
description = "IONEX (Ionosphere Maps) parser"
7+
homepage = "https://github.com/nav-solutions"
8+
repository = "https://github.com/nav-solutions/ionex"
9+
keywords = ["geo", "gnss", "gps", "galileo"]
10+
categories = ["science", "science::geo", "parsing"]
11+
edition = "2021"
12+
readme = "README.md"
13+
exclude = [
14+
"data/*",
15+
]
16+
17+
[package.metadata]
18+
msrv = "1.82"
19+
20+
[package.metadata.docs.rs]
21+
all-features = true
22+
rustdoc-args = ["--cfg", "docrs", "--generate-link-to-definition"]
23+
24+
[features]
25+
default = ["flate2"] # gzip files supported by default
26+
27+
[build-dependencies]
28+
serde_json = { version = "1.0", features = ["preserve_order"] }
29+
serde = { version = "1.0", default-features = false, features = ["derive"] }
30+
31+
[dependencies]
32+
geo = "0.30"
33+
thiserror = "2"
34+
itertools = "0.13.0"
35+
num-integer = "0.1.44" # TODO: see if we can get rid of div_ceil
36+
37+
# activate parser logs
38+
log = { version = "0.4", optional = true }
39+
40+
# support gzip files
41+
flate2 = { version = "1", optional = true }
42+
43+
gnss-rs = { version = "2.4", features = ["serde"] }
44+
hifitime = { version = "4.1", features = ["serde", "std"] }
45+
serde = { version = "1.0", optional = true, default-features = false, features = ["derive"] }
46+
47+
[dev-dependencies]
48+
log = "0.4"
49+
criterion = "0.5"
50+
env_logger = "0.11"
51+
52+
[[bench]]
53+
name = "parsing"
54+
harness = false
55+
56+
[[bench]]
57+
name = "formatting"
58+
harness = false

0 commit comments

Comments
 (0)