Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
134 commits
Select commit Hold shift + click to select a range
31ba1fe
Change knbt license to LGPL
BenWoodworth Mar 10, 2024
a918373
Update CI `checkout` and `setup-java` actions
BenWoodworth Mar 21, 2024
c0684e3
Add `NbtFormatBuilder` interface for shared NBT and SNBT options
BenWoodworth Mar 23, 2024
46501ad
Rename master branch to main
BenWoodworth Mar 27, 2024
e926015
Use Zulu JDK instead of Adopt for CI
BenWoodworth May 7, 2024
873ac58
Add vcs.xml to .gitignore
BenWoodworth Jun 2, 2024
d987d6a
WIP Update Kotlin to 2.0.20
BenWoodworth Mar 21, 2024
af6a7df
WIP Update Kotlin to 2.1.20
BenWoodworth Mar 21, 2025
8d18ebb
WIP Reformat code with the Kotlin 1.9.24 formatter
BenWoodworth May 14, 2024
7a8a2b9
WIP Revert "Reformat code with the Kotlin 1.9.24 formatter"
BenWoodworth Mar 21, 2025
cde9be6
WIP Reformat code with the K2 formatter
BenWoodworth Mar 21, 2025
3ae0b7e
Add explicit return types where missing
BenWoodworth Jun 2, 2024
ddd5302
Update kotlinx.serialization to 1.7.2
BenWoodworth May 23, 2024
8b320e9
WIP Update kotlinx.serialization to 1.8.0
BenWoodworth Mar 22, 2025
3b5d527
Update Okio to 3.9.0
BenWoodworth May 23, 2024
690bb7e
Use Parameterize instead of Kotest property testing
BenWoodworth May 23, 2024
c094e41
Use Parameterize instead of Kotest property testing (move files)
BenWoodworth May 23, 2024
7412200
Add `Parameter.reportedAs()` for parameterized tests
BenWoodworth May 24, 2024
78a21cc
Remove duplicate test for root compound nesting
BenWoodworth Jun 4, 2024
bfa2ea7
Remove class tests from `TreeNbtWriterTest` and `TreeNbtReaderTest`
BenWoodworth Jun 4, 2024
c018dbe
WIP Replace `NbtFormat()` and `SerializationTest` with `parameterOfVe…
BenWoodworth May 24, 2024
6d77f7d
WIP Reorganize test files
BenWoodworth Jun 5, 2024
3c542a4
WIP Rename `@NbtNamed` to `@NbtName`
BenWoodworth May 29, 2024
e673faa
WIP Add NbtNamed
BenWoodworth May 31, 2024
f640b8a
Update the `encodeToNbtTag` and `decodeFromNbtTag` docs
BenWoodworth May 31, 2024
f13a1d1
Change `NbtFormat` into a class
BenWoodworth Jun 6, 2024
b4cd6ab
Change `Nbt` and `StringifiedNbt` to not be sealed
BenWoodworth Jun 6, 2024
6abf5cd
Fix `StringifiedNbtConfiguration.toString()`
BenWoodworth Jun 6, 2024
e2ed182
WIP Make NbtFormat usable on its own
BenWoodworth Jun 6, 2024
3e791f3
WIP Move named root check into encoder/decoder
BenWoodworth Jun 6, 2024
83b6e7c
WIP Refactor `NbtException`
BenWoodworth Jun 13, 2024
6b045de
Remove path tracking from `NbtReaderDecoder`
BenWoodworth Jun 14, 2024
e90e90c
WIP Fix decoder checking list/array entries when the size is known
BenWoodworth Jun 26, 2024
56d3495
WIP Fix decoder checking list/array entries when the size is known
BenWoodworth Jun 26, 2024
35a5875
WIP Fix decoder checking list/array entries when the size is known
BenWoodworth Jun 29, 2024
358697a
WIP Remove unnecessary implementations for `begin*Entry` in readers w…
BenWoodworth Jun 30, 2024
ca02d45
WIP Remove unnecessary implementations for `begin*Entry` in readers w…
BenWoodworth Jun 30, 2024
af3ef3a
Add `KClass.qualifiedNameOrDefault()` for tests
BenWoodworth Jul 12, 2024
5738d41
WIP Add `@NbtName.Dynamic`
BenWoodworth Jun 10, 2024
4319f1e
WIP Add `@NbtName.Dynamic`
BenWoodworth Jun 26, 2024
3b02a40
WIP Add `@NbtName.Dynamic`
BenWoodworth Jul 12, 2024
88da73e
WIP Add `@NbtName.Dynamic`
BenWoodworth Jul 12, 2024
bab1d19
WIP Add `@NbtName.Dynamic`
BenWoodworth Aug 9, 2024
b51d145
WIP Add `@NbtName.Dynamic`
BenWoodworth Sep 1, 2024
80bc021
WIP Add `@NbtName.Dynamic` <- removed dynamic delegation checks
BenWoodworth Aug 30, 2024
36e078d
Change VerifyingNbtWriter list/array size checks to be precise
BenWoodworth Jul 14, 2024
60ef035
Improve VerifyingNbtWriter checks/messages
BenWoodworth Jul 23, 2024
45eabdf
Improve VerifyingNbtWriter checks/messages
BenWoodworth Jul 25, 2024
0a8eb4f
Improve VerifyingNbtWriter checks/messages
BenWoodworth Jul 25, 2024
3821e53
Improve VerifyingNbtWriter checks/messages
BenWoodworth Jul 25, 2024
dd8c6f2
Improve VerifyingNbtWriter checks/messages
BenWoodworth Jul 25, 2024
8353e32
Improve VerifyingNbtWriter checks/messages
BenWoodworth Jul 26, 2024
c143f56
Improve VerifyingNbtWriter checks/messages
BenWoodworth Jul 26, 2024
4f0e4ee
Improve VerifyingNbtWriter checks/messages
BenWoodworth Jul 26, 2024
5d1c6a2
WIP Improve `VerifyingNbtWriter`/`Reader` checks
BenWoodworth Jul 27, 2024
fc6d91f
Separate out `NbtWriterEncoder.endStructure()` logic
BenWoodworth Jul 14, 2024
5830cd7
Separate out `encode`/`decodeNbtTag()` logic
BenWoodworth Aug 6, 2024
69d723b
Parameterize `ArraySerializer` test suite
BenWoodworth Aug 8, 2024
539bf5a
Remove array tests from `ListSerializerTest`
BenWoodworth Aug 19, 2024
cdfcdb8
Make the `ListSerializerTest` suite more thorough
BenWoodworth Aug 19, 2024
f543680
Remove fast-path array serialization for the time being
BenWoodworth Aug 19, 2024
a5a4317
WIP Don't serialize as TAG_*Array unless marked with `@NbtArray`
BenWoodworth Aug 19, 2024
60c52a7
WIP Don't serialize as TAG_*Array unless marked with `@NbtArray`
BenWoodworth Aug 30, 2024
e186bd3
WIP Enable `@NbtName` for all types
BenWoodworth Jun 24, 2024
1555308
WIP Enable `@NbtName` for all types
BenWoodworth Jul 14, 2024
4e225a6
WIP Enable `@NbtName` for all types
BenWoodworth Aug 6, 2024
3ea9e6b
WIP Enable `@NbtName` for all types
BenWoodworth Aug 6, 2024
bbd84e1
WIP Enable `@NbtName` for all types
BenWoodworth Aug 8, 2024
33ef8c5
WIP Enable `@NbtName` for all types <- starting decoder
BenWoodworth Aug 10, 2024
81c43a4
WIP Enable `@NbtName` for all types <- starting decoder
BenWoodworth Aug 10, 2024
cebf319
WIP Enable `@NbtName` for all types <- starting decoder
BenWoodworth Aug 10, 2024
c7516e2
WIP Enable `@NbtName` for all types <- starting decoder
BenWoodworth Aug 10, 2024
7acb7c2
WIP Enable `@NbtName` for all types <- starting decoder
BenWoodworth Aug 10, 2024
2b1bbef
WIP Enable `@NbtName` for all types <- starting decoder
BenWoodworth Aug 10, 2024
b48c320
WIP Enable `@NbtName` for all types <- starting decoder
BenWoodworth Aug 30, 2024
2768bea
WIP Enable `@NbtName` for all types <- cleanup
BenWoodworth Sep 4, 2024
563a62a
WIP Improve variable names to distinguish decoded/serializer info
BenWoodworth Jul 11, 2024
a4d4254
WIP Add methods for encoding/decoding NBT names dynamically
BenWoodworth Jun 21, 2024
ad85a3e
WIP Add methods for encoding/decoding NBT names dynamically
BenWoodworth Jun 21, 2024
29a13e0
WIP Add methods for encoding/decoding NBT names dynamically
BenWoodworth Jun 24, 2024
f3b91c3
WIP Add methods for encoding/decoding NBT names dynamically
BenWoodworth Jul 9, 2024
b39ba9f
WIP Add methods for encoding/decoding NBT names dynamically
BenWoodworth Jul 9, 2024
9c968fe
WIP Add methods for encoding/decoding NBT names dynamically
BenWoodworth Jul 12, 2024
f9888cd
WIP Add methods for encoding/decoding NBT names dynamically
BenWoodworth Jul 12, 2024
04333cb
WIP Add methods for encoding/decoding NBT names dynamically
BenWoodworth Jul 12, 2024
e581c38
WIP Add methods for encoding/decoding NBT names dynamically
BenWoodworth Jul 13, 2024
d0d402c
WIP Add methods for encoding/decoding NBT names dynamically
BenWoodworth Aug 18, 2024
86188a4
WIP Add methods for encoding/decoding NBT names dynamically
BenWoodworth Aug 31, 2024
1ea32dd
WIP Add methods for encoding/decoding NBT names dynamically <- implem…
BenWoodworth Aug 31, 2024
9724604
WIP Add methods for encoding/decoding NBT names dynamically <- implem…
BenWoodworth Aug 31, 2024
80007c5
WIP Add methods for encoding/decoding NBT names dynamically <- implem…
BenWoodworth Aug 31, 2024
9ef11fd
WIP Add methods for encoding/decoding NBT names dynamically <- implem…
BenWoodworth Aug 31, 2024
3b205e1
Make `NbtNamed` serializable
BenWoodworth Aug 31, 2024
289197b
WIP Allow `NbtNamed<NbtTag>` for serialized representation in tests
BenWoodworth Sep 1, 2024
b202ea1
Change named `buildNbtCompound`/`List` to return `NbtNamed`
BenWoodworth Sep 1, 2024
4175451
Update tests for named tags to use `NbtNamed`
BenWoodworth Sep 1, 2024
a92c6f6
WIP Only encode `NbtName` at root
BenWoodworth Sep 1, 2024
3d34b0c
WIP Only encode `NbtName` at root
BenWoodworth Sep 1, 2024
42910f1
Add `definiteLengthEncoding` to `NbtCapabilities`
BenWoodworth Sep 2, 2024
4afb0cf
Rename `CompoundEntryInfo` to `NamedTagInfo`
BenWoodworth Sep 2, 2024
435e5cb
Remove `NbtTag.primitive` convenience properties
BenWoodworth Sep 4, 2024
42b2084
Add convenience properties for `NbtNamed<NbtTag>`
BenWoodworth Sep 3, 2024
47a1b2c
WIP [NEW] Change NbtName representation from compound nesting
BenWoodworth Sep 3, 2024
cb1705d
WIP [NEW] Change NbtName repsentation from compound nesting
BenWoodworth Sep 4, 2024
d99bfa5
WIP [NEW] Change NbtName repsentation from compound nesting
BenWoodworth Sep 4, 2024
d792b32
WIP [NEW] Change NbtName repsentation from compound nesting
BenWoodworth Sep 5, 2024
aee8916
WIP [NEW] Change NbtName repsentation from compound nesting
BenWoodworth Sep 5, 2024
9ed58f0
WIP [NEW] Change NbtName repsentation from compound nesting
BenWoodworth Sep 5, 2024
b97e421
WIP Make every serializable type have an implicit `NbtName`
BenWoodworth Sep 5, 2024
d5144b9
Change `element` to `tag` in `NbtTransformingSerializer`
BenWoodworth Sep 7, 2024
4e5868a
Change `encode`/`decodeNbtTag` to serialize named tags
BenWoodworth Sep 7, 2024
1a5a3c7
Move `NbtFormatBuilder`s next to their configurations
BenWoodworth Sep 6, 2024
c0080e4
Change builder constructors to take a nullable `from`
BenWoodworth Sep 10, 2024
de06a0b
WIP Rename `Nbt` to `BinaryNbtFormat`
BenWoodworth Sep 10, 2024
741466c
WIP Split in-memory NBT into its own format
BenWoodworth Sep 9, 2024
88a4e18
WIP Make NbtFormat abstract
BenWoodworth Sep 10, 2024
997f523
WIP Separate `BinaryNbtFormat` into variants
BenWoodworth Sep 10, 2024
a80155e
Merge `NbtVariant` into `BinaryNbtFormat`
BenWoodworth Sep 10, 2024
7579963
WIP Format-specific `encodeTo`/`decodeFromNbtTag` functions
BenWoodworth Sep 11, 2024
3bbbfb0
WIP Format-specific `encodeTo`/`decodeFromNbtTag` functions
BenWoodworth Sep 11, 2024
120a4e8
WIP Format-specific `encodeTo`/`decodeFromNbtTag` functions
BenWoodworth Mar 27, 2025
6b3d059
Add BedrockNetwork protocolVersion option
BenWoodworth Sep 12, 2024
bffbde0
Add `lenientNbtNames` option
BenWoodworth Sep 13, 2024
2b81f63
Fix JavaNetworkNbtTest using unsupported tag types
BenWoodworth Mar 20, 2025
d1be02f
WIP Add `NbtCapabilities.rootTagTypes`
BenWoodworth Sep 16, 2024
f7f63dc
WIP Add `NbtCapabilities.rootTagTypes`
BenWoodworth Dec 19, 2024
599c6d8
WIP Add `NbtCapabilities.rootTagTypes`
BenWoodworth Mar 20, 2025
72c98c7
WIP Expose `NbtTagType` in the API
BenWoodworth Mar 26, 2025
a324e48
WIP Expose `NbtType` in the API
BenWoodworth Apr 17, 2025
15fd84f
WIP Expose `NbtType` in the API (move files)
BenWoodworth Apr 17, 2025
aa38610
WIP Add `SerialDescriptorNbtType`
BenWoodworth Apr 19, 2025
d03c652
WIP Support empty `NbtList`s of any element type
BenWoodworth Mar 28, 2025
8b74ffe
WIP Add `NbtDecoder.decodeNbtType()`
BenWoodworth Mar 27, 2025
e270831
WIP Support null root values in `NbtFormat`s
BenWoodworth Mar 26, 2025
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
35 changes: 24 additions & 11 deletions .github/workflows/publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ name: Publish
on:
push:
tags: [ 'v*' ]
branches: [ 'master', '[0-9]+.[0-9]+', '[0-9]+.[0-9]+.[0-9]+' ]
branches: [ 'main', '[0-9]+.[0-9]+', '[0-9]+.[0-9]+.[0-9]+' ]

env:
GIT_REF: ${{ github.ref }}
Expand All @@ -18,37 +18,50 @@ jobs:
name: "Publish: multiplatform, jvm, js, linux, mingw"
runs-on: windows-latest
steps:
- uses: actions/checkout@v3
- uses: actions/checkout@v4
- name: Set up JDK 8
uses: actions/setup-java@v3
uses: actions/setup-java@v4
with:
java-version: '8'
distribution: 'adopt'
distribution: 'zulu'
- name: Clean
if: ${{ false }} # Skip, since it fails on Windows: https://youtrack.jetbrains.com/issue/KT-50545/
run: .\gradlew.bat clean
- name: Publish to Maven
run: >-
.\gradlew.bat clean
.\gradlew.bat
publishKotlinMultiplatformPublicationToMavenRepository
publishJvmPublicationToMavenRepository
publishJsPublicationToMavenRepository
publishLinuxX64PublicationToMavenRepository
publishLinuxArm64PublicationToMavenRepository
publishMingwX64PublicationToMavenRepository

macos:
name: "Publish: macos, ios, watchos"
runs-on: macos-latest
steps:
- uses: actions/checkout@v3
- uses: actions/checkout@v4
- name: Set up JDK 8
uses: actions/setup-java@v3
uses: actions/setup-java@v4
with:
java-version: '8'
distribution: 'adopt'
distribution: 'zulu'
- name: Clean
run: ./gradlew clean
- name: Publish to Maven
run: >-
./gradlew clean
./gradlew
publishMacosX64PublicationToMavenRepository
publishIosArm64PublicationToMavenRepository
publishMacosArm64PublicationToMavenRepository
publishIosSimulatorArm64PublicationToMavenRepository
publishIosX64PublicationToMavenRepository
publishWatchosSimulatorArm64PublicationToMavenRepository
publishWatchosX64PublicationToMavenRepository
publishWatchosArm32PublicationToMavenRepository
publishWatchosArm64PublicationToMavenRepository
publishWatchosX86PublicationToMavenRepository
publishTvosSimulatorArm64PublicationToMavenRepository
publishTvosX64PublicationToMavenRepository
publishTvosArm64PublicationToMavenRepository
publishIosArm64PublicationToMavenRepository
publishWatchosDeviceArm64PublicationToMavenRepository
30 changes: 18 additions & 12 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,12 +7,12 @@ jobs:
name: "Test: jvm, js, linux"
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: actions/checkout@v4
- name: Set up JDK 8
uses: actions/setup-java@v3
uses: actions/setup-java@v4
with:
java-version: '8'
distribution: 'adopt'
distribution: 'zulu'
- name: Clean
run: ./gradlew clean
- name: Test
Expand All @@ -22,28 +22,34 @@ jobs:
name: "Test: mingw"
runs-on: windows-latest
steps:
- uses: actions/checkout@v3
- uses: actions/checkout@v4
- name: Set up JDK 8
uses: actions/setup-java@v3
uses: actions/setup-java@v4
with:
java-version: '8'
distribution: 'adopt'
distribution: 'zulu'
- name: Clean
if: ${{ false }} # Skip, since it fails on Windows: https://youtrack.jetbrains.com/issue/KT-50545/
run: .\gradlew.bat clean
- name: Test
run: .\gradlew.bat mingwX64Test

macos:
name: "Test: macos, ios, watchos"
name: "Test: macos, ios, watchos, tvos"
runs-on: macos-latest
steps:
- uses: actions/checkout@v3
- uses: actions/checkout@v4
- name: Set up JDK 8
uses: actions/setup-java@v3
uses: actions/setup-java@v4
with:
java-version: '8'
distribution: 'adopt'
distribution: 'zulu'
- name: Clean
run: ./gradlew clean
- name: Test # TODO Arm tests: iosArm64Test watchosArm32Test watchosArm64Test
run: ./gradlew macosX64Test iosX64Test watchosX86Test
- name: Test
run: >
./gradlew
macosArm64Test macosX64Test
iosSimulatorArm64Test iosX64Test
tvosSimulatorArm64Test tvosX64Test
watchosSimulatorArm64Test watchosX64Test
5 changes: 4 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
@@ -1,8 +1,11 @@
.DS_Store

# Kotlin
.kotlin/

# IntelliJ files
**/.idea/*
!/.idea/vcs.xml
!/.idea/codeStyles
out/
*.iml

Expand Down
11 changes: 11 additions & 0 deletions .idea/codeStyles/Project.xml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

5 changes: 5 additions & 0 deletions .idea/codeStyles/codeStyleConfig.xml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

30 changes: 0 additions & 30 deletions .idea/vcs.xml

This file was deleted.

Loading
Loading