1
0
mirror of synced 2026-10-13 01:56:12 +08:00

Compare commits

...

2 Commits

4 changed files with 8 additions and 4 deletions

View File

@@ -16,7 +16,7 @@ lunar是一款无第三方依赖的公历(阳历)、农历(阴历、老黄历)
<dependency>
<groupId>cn.6tail</groupId>
<artifactId>lunar</artifactId>
<version>1.3.0</version>
<version>1.3.1</version>
</dependency>
```

View File

@@ -12,7 +12,7 @@ lunar is a calendar library for Solar and Chinese Lunar.
<dependency>
<groupId>cn.6tail</groupId>
<artifactId>lunar</artifactId>
<version>1.3.0</version>
<version>1.3.1</version>
</dependency>
```

View File

@@ -7,7 +7,7 @@
<groupId>cn.6tail</groupId>
<artifactId>lunar</artifactId>
<packaging>jar</packaging>
<version>1.3.0</version>
<version>1.3.1</version>
<name>${project.groupId}:${project.artifactId}</name>
<url>https://github.com/6tail/lunar-java</url>
<description>a calendar library for Solar and Chinese Lunar</description>

View File

@@ -293,9 +293,13 @@ public class Solar {
offsetYear += 60;
}
int startYear = today.getYear() - offsetYear - 1;
while (startYear >= baseYear) {
while (true) {
years.add(startYear);
startYear -= 60;
if (startYear < baseYear) {
years.add(baseYear);
break;
}
}
int hour = 0;
String timeZhi = timeGanZhi.substring(1);