mirror of
https://github.com/catppuccin/java.git
synced 2026-01-09 05:21:27 +08:00
fix(palette): incorrect rgb channel ordering (#32)
* fix(palette): incorrect rgb channel ordering * tests(palette): remove "built-in" tests * ci(deploy): switch to token based auth
This commit is contained in:
parent
9dab36b850
commit
b0d472df3b
6
.github/workflows/deploy.yml
vendored
6
.github/workflows/deploy.yml
vendored
@ -20,7 +20,7 @@ jobs:
|
||||
cache: 'maven'
|
||||
server-id: ossrh
|
||||
server-username: OSSRH_USERNAME
|
||||
server-password: OSSRH_PASSWORD
|
||||
server-password: OSSRH_TOKEN
|
||||
gpg-private-key: ${{ secrets.MAVEN_GPG_PRIVATE_KEY }}
|
||||
gpg-passphrase: MAVEN_GPG_PASSPHRASE
|
||||
|
||||
@ -29,8 +29,8 @@ jobs:
|
||||
|
||||
- name: Deploy
|
||||
env:
|
||||
OSSRH_USERNAME: catppuccin
|
||||
OSSRH_PASSWORD: ${{ secrets.OSSRH_PASSWORD }}
|
||||
OSSRH_USERNAME: ${{ secrets.OSSRH_USERNAME }}
|
||||
OSSRH_TOKEN: ${{ secrets.OSSRH_TOKEN }}
|
||||
MAVEN_GPG_PASSPHRASE: ${{ secrets.MAVEN_GPG_PASSPHRASE }}
|
||||
run: mvn -B -DskipTests deploy
|
||||
|
||||
|
||||
@ -5,12 +5,12 @@
|
||||
<parent>
|
||||
<artifactId>catppuccin-java</artifactId>
|
||||
<groupId>com.catppuccin</groupId>
|
||||
<version>2.0.2</version>
|
||||
<version>2.0.3</version>
|
||||
</parent>
|
||||
|
||||
<packaging>jar</packaging>
|
||||
<artifactId>catppuccin-palette</artifactId>
|
||||
<version>2.0.2</version>
|
||||
<version>2.0.3</version>
|
||||
<name>catppuccin-palette</name>
|
||||
|
||||
<properties>
|
||||
@ -23,7 +23,7 @@
|
||||
<dependency>
|
||||
<groupId>com.catppuccin</groupId>
|
||||
<artifactId>catppuccin-processing</artifactId>
|
||||
<version>1.0.1</version>
|
||||
<version>1.0.2</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>org.junit.jupiter</groupId>
|
||||
@ -44,7 +44,7 @@
|
||||
<annotationProcessorPath>
|
||||
<groupId>com.catppuccin</groupId>
|
||||
<artifactId>catppuccin-processing</artifactId>
|
||||
<version>1.0.1</version>
|
||||
<version>1.0.2</version>
|
||||
</annotationProcessorPath>
|
||||
</annotationProcessorPaths>
|
||||
<annotationProcessors>
|
||||
|
||||
@ -14,7 +14,7 @@ public class Color {
|
||||
* @param b the green value
|
||||
* @param g the blue value
|
||||
*/
|
||||
public Color(int r, int b, int g) {
|
||||
public Color(int r, int g, int b) {
|
||||
this.r = r;
|
||||
this.g = g;
|
||||
this.b = b;
|
||||
|
||||
@ -14,13 +14,13 @@ class Oled extends BuiltinPalettes.Mocha {
|
||||
public class PaletteTests {
|
||||
@Test
|
||||
public void mochaExistsAndReturnsCorrectDetails() {
|
||||
assertEquals("mocha", Palette.MOCHA.name(), "mocha to have the correct name");
|
||||
}
|
||||
|
||||
@Test
|
||||
public void builtinMochaExistsAndReturnsCorrectDetails() {
|
||||
BuiltinPalettes.Mocha palette = BuiltinPalettes.MOCHA;
|
||||
assertEquals("mocha", palette.name(), "mocha to have the correct name");
|
||||
Flavor mocha = Palette.MOCHA;
|
||||
assertEquals("mocha", mocha.name(), "mocha to have the correct name");
|
||||
assertEquals(mocha.base().hex(), "1e1e2e");
|
||||
assertEquals(mocha.base().r(), 30);
|
||||
assertEquals(mocha.base().g(), 30);
|
||||
assertEquals(mocha.base().b(), 46);
|
||||
assertArrayEquals(mocha.base().components(), new int[]{30, 30, 46});
|
||||
}
|
||||
|
||||
@Test
|
||||
@ -28,34 +28,16 @@ public class PaletteTests {
|
||||
assertEquals("frappe", Palette.FRAPPE.name(), "frappe to have the correct name");
|
||||
}
|
||||
|
||||
@Test
|
||||
public void builtinFrappeExistsAndReturnsCorrectDetails() {
|
||||
BuiltinPalettes.Frappe palette = BuiltinPalettes.FRAPPE;
|
||||
assertEquals("frappe", palette.name(), "frappe to have the correct name");
|
||||
}
|
||||
|
||||
@Test
|
||||
public void macchiatoExistsAndReturnsCorrectDetails() {
|
||||
assertEquals("macchiato", Palette.MACCHIATO.name(), "macchiato to have the correct name");
|
||||
}
|
||||
|
||||
@Test
|
||||
public void builtinMacchiatoExistsAndReturnsCorrectDetails() {
|
||||
BuiltinPalettes.Macchiato palette = BuiltinPalettes.MACCHIATO;
|
||||
assertEquals("macchiato", palette.name(), "macchiato to have the correct name");
|
||||
}
|
||||
|
||||
@Test
|
||||
public void latteExistsAndReturnsCorrectDetails() {
|
||||
assertEquals("latte", Palette.LATTE.name(), "latte to have the correct name");
|
||||
}
|
||||
|
||||
@Test
|
||||
public void builtinLatteExistsAndReturnsCorrectDetails() {
|
||||
BuiltinPalettes.Latte palette = BuiltinPalettes.LATTE;
|
||||
assertEquals("latte", palette.name(), "latte to have the correct name");
|
||||
}
|
||||
|
||||
@Test
|
||||
public void oledOverridesProperly() {
|
||||
Flavor mocha = Palette.MOCHA;
|
||||
|
||||
4
pom.xml
4
pom.xml
@ -5,7 +5,7 @@
|
||||
|
||||
<groupId>com.catppuccin</groupId>
|
||||
<artifactId>catppuccin-java</artifactId>
|
||||
<version>2.0.2</version>
|
||||
<version>2.0.3</version>
|
||||
<packaging>pom</packaging>
|
||||
<name>catppuccin-java</name>
|
||||
<description>Soothing pastel library for Catppuccin</description>
|
||||
@ -58,7 +58,7 @@
|
||||
<dependency>
|
||||
<groupId>com.catppuccin</groupId>
|
||||
<artifactId>catppuccin-processing</artifactId>
|
||||
<version>1.0.1</version>
|
||||
<version>1.0.2</version>
|
||||
</dependency>
|
||||
</dependencies>
|
||||
</dependencyManagement>
|
||||
|
||||
@ -5,12 +5,12 @@
|
||||
<parent>
|
||||
<artifactId>catppuccin-java</artifactId>
|
||||
<groupId>com.catppuccin</groupId>
|
||||
<version>2.0.2</version>
|
||||
<version>2.0.3</version>
|
||||
</parent>
|
||||
|
||||
<packaging>jar</packaging>
|
||||
<artifactId>catppuccin-processing</artifactId>
|
||||
<version>1.0.1</version>
|
||||
<version>1.0.2</version>
|
||||
<name>catppuccin-processing</name>
|
||||
<description>Soothing pastel code generator for Catppuccin</description>
|
||||
<url>https://github.com/catppuccin/java</url>
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user