Commit graph

754 commits

Author SHA1 Message Date
Alexander Söderberg
f1582fb64e feat(annotations): add command containers (#364)
This is the first part of the introduction of annotation processing to cloud. A new `@CommandContainer` annotation has been introduced, which can be placed on classes to have the annotation parser automatically construct & parse the classes when `AnnotationParser.parseContainers()` is invoked.

A future PR will introduce another processor that will scan for `@CommandMethod` annotations and verify the integrity of the annotated methods (visibility, argument annotations, etc.).
2022-06-18 22:52:58 -07:00
Alexander Söderberg
d613fd0208 feat(core): add MulticastDelegateFutureCommandExecutionHandler (#363)
This PR also adds a `handler()` getter to the command builder class. This will allow for things along the line of https://github.com/Incendo/cloud/issues/189 to be achieved.
2022-06-18 22:52:58 -07:00
Citymonstret
c39e0517fa chore: add test for issue #281
cannot replicate the issue (anymore).
2022-06-18 22:52:58 -07:00
Citymonstret
0ee576657b chore: add tests for issue #262
Add tests in order to try to replicate #262. The issue cannot be replicated.
2022-06-18 22:52:58 -07:00
Alexander Söderberg
09044b9c1b feat(core): add unit tests for the standard parsers (#362)
* feat(core): add BooleanParser unit tests

* feat(core): add ByteParser unit tests

* feat(core): add IntegerParser, LongParser & ShortParser unit tests

* feat(core): add EnumParser unit tests

* feat(core): add CharacterParser unit tests

* feat(core): add DoubleParser & FloatParser unit tests

* feat(core): add UUIDParser & StringArrayParser unit tests
2022-06-18 22:52:58 -07:00
Alexander Söderberg
46a3f7129f build: add revapi to core api modules (#361)
this way we can detect API/ABI breaks between versions. it'll compare to the previous tag.
2022-06-18 22:52:58 -07:00
Citymonstret
236cd34a32 build: add test results as comment 2022-06-18 22:52:58 -07:00
Citymonstret
ebb25e9d41 chore(core): improve (some) tests 2022-06-18 22:52:58 -07:00
Jason Penilla
db17fb5d10 Update paper repo 2022-06-18 22:52:58 -07:00
Jason Penilla
5849f471a7 Remove no longer needed licenser references 2022-06-18 22:52:58 -07:00
Jason Penilla
21aa30eab7 Switch plugin application order on fabric module
Fixes natives download on macOS by allowing loom to put mojang's repo first
2022-06-18 22:52:58 -07:00
Jason Penilla
1e2b7f8b8a Update gradle wrapper & add .gitattributes 2022-06-18 22:52:58 -07:00
Citymonstret
4ffd077165 chore: update CHANGELOG.md 2022-06-18 22:52:58 -07:00
Alexander Söderberg
f3e95070ce fix: #337 NPE thrown on empty command tree (#358)
Fixes #337 by making an empty command three throw NoSuchCommandException instead of NullPointerException.
2022-06-18 22:52:58 -07:00
Aldin
2277bf5ef8 feat: allow a custom CaptionVariableReplacementHandler (#352) 2022-06-18 22:52:58 -07:00
solo
7b23dd0329 Fix Kotlin and Java interop issues. (#343)
The following PR fixes interop issues between Kotlin and Java.

Currently, there is no way to go from `Command.Builder` -> `MutableCommandBuilder`, nor from `MutableCommandBuilder` -> `Command.Builder`.

This PR fixes it by introducing
- A new constructor for `MutableCommandBuilder`:
  
  ```kotlin
  public constructor(commandBuilder: Command.Builder<C>, commandManager: CommandManager<C>)
  ```
- Making the `commandBuilder` variable public
- Adding the following extensions
  
  ```kotlin
  public fun <C : Any> Command.Builder<C>.toMutable(commandManager: CommandManager<C>): MutableCommandBuilder<C>
  
  public fun <C : Any> Command.Builder<C>.mutate(commandManager: CommandManager<C>, lambda: MutableCommandBuilder<C>.() -> Unit): MutableCommandBuilder<C>
  ```
2022-06-18 22:52:58 -07:00
Citymonstret
fc27fa5b51 chore(annotations): fix formatting issues 2022-06-18 22:52:58 -07:00
Alexander Söderberg
40b51676fe feat(minecraft): support sender-aware description decorators (#354) 2022-06-18 22:52:58 -07:00
Alexander Söderberg
d681ba5840 feat: annotation string processors (#353)
adds a system for processing strings found in annotations before they're used by AnnotationParser

implements #347

Also, because we're using "-Werror", the code won't actually build (and thus tests won't work) using JDK18. To remedy this, a bunch of @SuppressWarnings("serial")s has been added to the exceptions. We don't serialize exceptions, and they're in fact non-serializable because of their members, so this is the appropriate solution (well, the better solution would be to make them serializable, but that's outside the scope of this PR).
2022-06-18 22:52:58 -07:00
zml
ed7b7569a8 build: switch to spotless (#355)
* build: switch to spotless

add in some other basic formatting steps that allow for easy
auto-correction

* build: lint text files as well

* chore: remove license headers from package-info files

spotless can't verify these
2022-06-18 22:52:58 -07:00
Aldin
cc7793925d Register missing regex failure caption (#351) 2022-06-18 22:52:58 -07:00
Jason Penilla
84857313db always apply sonatype publishing plugin 2022-06-18 22:52:58 -07:00
Jason Penilla
3d31688952 remove old snapshot publishing repo 2022-06-18 22:52:58 -07:00
Jason Penilla
eae247954f build and publishing updates 2022-06-18 22:52:58 -07:00
Jason Penilla
a8932bc307 Update gradle wrapper 2022-06-18 22:52:58 -07:00
Jason
b3db0aab38 Improved KeyedWorldArgument suggestions (#334) 2022-06-18 22:52:58 -07:00
Jason Penilla
b0289e8d01 DurationArgument cleanup 2022-06-18 22:52:58 -07:00
Aldin
c58248e35d Register the duration argument parser in the default parser registry (#333) 2022-06-18 22:52:58 -07:00
Tadhg Boyle
c2b3145d4d Add DurationArgument for parsing java.time.Duration (#330)
Co-authored-by: Frank van der Heijden <frank.boekanier@gmail.com>
2022-06-18 22:52:58 -07:00
Jason Penilla
52f3e2c679 back to 1.7.0-SNAPSHOT 2022-06-18 22:52:58 -07:00
Citymonstret
018950fda8
build(pircbotx): bump pircbotx version 2022-06-02 11:33:17 +02:00
Citymonstret
10bdabf587
docs: update links 2022-06-01 17:58:20 +02:00
Jason Penilla
27ae568966
Update docs regarding snapshot builds 2022-03-10 15:29:56 -07:00
Jason Penilla
d7182807de
Update changelog 2022-02-28 14:03:07 -07:00
Jason Penilla
7c6a01e414
release: Version 1.6.2 2022-02-28 13:59:58 -07:00
Jason Penilla
0623bcb050 Update changelog 2022-02-28 13:57:35 -07:00
Jason Penilla
c26fbcb6fc Fix incorrect inputQueue usage in some argument types 2022-02-28 13:57:35 -07:00
Jason Penilla
33c51967e2 build updates 2022-02-28 13:57:35 -07:00
Jason Penilla
1c02da5116 Update commodore 2022-02-28 13:57:35 -07:00
Jason Penilla
3d2d850533 Update MinecraftArgumentTypes util for 1.18.2 2022-02-28 13:57:35 -07:00
Jason Penilla
5fb18ddc6e Update BlockPredicateArgument for 1.18.2 2022-02-28 13:57:35 -07:00
lucko
29b780358b Update commodore version 2022-02-28 13:57:35 -07:00
Jason Penilla
e30d79d342 update gradle plugins 2022-02-28 13:57:35 -07:00
zml
a06e592d4a fix velocity build (#332) 2022-02-28 13:57:35 -07:00
Jason Penilla
36833588d3 1.6.2-SNAPSHOT 2022-02-28 13:57:35 -07:00
Jason Penilla
1f33942d03
Update README 2022-01-06 11:58:27 -08:00
Jason Penilla
e187a1cc24
release: Version 1.6.1 2021-12-18 04:14:25 -08:00
Jason Penilla
5a2d3a3488 set version to 1.6.1-SNAPSHOT 2021-12-18 04:12:42 -08:00
Jason Penilla
c4b77b3190 update changelog 2021-12-18 04:12:42 -08:00
Jason Penilla
d8b6dec80f reword comment 2021-12-18 04:12:42 -08:00