Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
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
29 changes: 0 additions & 29 deletions .circleci/config.yml

This file was deleted.

2 changes: 1 addition & 1 deletion .github/FUNDING.yml
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
# These are supported funding model platforms

github: doyaaaaaken
github: jsoizo
49 changes: 49 additions & 0 deletions .github/workflows/build_and_test.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,49 @@
name: Build and Test

on:
push:
branches:
- main
pull_request:

jobs:
build:
runs-on: ubuntu-latest

steps:
- name: Checkout code
uses: actions/checkout@v4

- name: Set up JDK 8
uses: actions/setup-java@v4
with:
distribution: 'temurin'
java-version: '8'

- name: Setup Gradle
uses: gradle/actions/setup-gradle@v4

- name: Cache Gradle dependencies
uses: actions/cache@v4
with:
path: |
~/.gradle/caches
~/.gradle/wrapper
key: ${{ runner.os }}-gradle-${{ hashFiles('**/*.gradle*', '**/gradle-wrapper.properties') }}
restore-keys: |
${{ runner.os }}-gradle-

- name: Verify dependencies
run: ./gradlew dependencies

- name: Run checks and generate report
run: |
./gradlew clean check
./gradlew jacocoTestReport

- name: Upload coverage report to Codecov
uses: codecov/codecov-action@v4
with:
fail_ci_if_error: true
token: ${{ secrets.CODECOV_TOKEN }}
verbose: true
51 changes: 27 additions & 24 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,16 +1,15 @@
<h1 align="center">kotlin-csv</h1>

<p>
<img alt="Version" src="https://img.shields.io/badge/version-1.9.3-blue.svg?cacheSeconds=2592000" />
<a href="https://github.com/doyaaaaaken/kotlin-csv/blob/master/LICENSE">
<img alt="Version" src="https://img.shields.io/badge/version-1.10.0-blue.svg?cacheSeconds=2592000" />
<a href="https://github.com/jsoizo/kotlin-csv/blob/master/LICENSE">
<img alt="License: Apache License 2.0" src="https://img.shields.io/badge/License-Apache License 2.0-yellow.svg" target="_blank" />
</a>
<img alt="CircleCI" src="https://circleci.com/gh/doyaaaaaken/kotlin-csv/tree/master.svg?style=svg" />
<a href="https://codecov.io/gh/doyaaaaaken/kotlin-csv">
<img src="https://codecov.io/gh/doyaaaaaken/kotlin-csv/branch/master/graph/badge.svg" alt="codecov" />
<a href="https://codecov.io/gh/jsoizo/kotlin-csv">
<img src="https://codecov.io/gh/jsoizo/kotlin-csv/branch/master/graph/badge.svg" alt="codecov" />
</a>
<a href="https://www.codefactor.io/repository/github/doyaaaaaken/kotlin-csv">
<img src="https://www.codefactor.io/repository/github/doyaaaaaken/kotlin-csv/badge" alt="CodeFactor" />
<a href="https://www.codefactor.io/repository/github/jsoizo/kotlin-csv">
<img src="https://www.codefactor.io/repository/github/jsoizo/kotlin-csv/badge" alt="CodeFactor" />
</a>
</p>

Expand Down Expand Up @@ -38,36 +37,40 @@ Pure Kotlin CSV Reader/Writer.

### Gradle

```gradle
// Gradle Kotlin DSL
implementation("com.github.doyaaaaaken:kotlin-csv-jvm:1.9.3") // for JVM platform
implementation("com.github.doyaaaaaken:kotlin-csv-js:1.9.3") // for Kotlin JS platform
for Kotlin DSL

// Gradle Groovy DSL
implementation 'com.github.doyaaaaaken:kotlin-csv-jvm:1.9.3' // for JVM platform
implementation 'com.github.doyaaaaaken:kotlin-csv-js:1.9.3' // for Kotlin JS platform
```kotlin
implementation("com.jsoizo:kotlin-csv-jvm:1.10.0") // for JVM platform
implementation("com.jsoizo:kotlin-csv-js:1.10.0") // for Kotlin JS platform
```

for Gradle DSL

```groovy
implementation 'com.jsoizo:kotlin-csv-jvm:1.10.0' // for JVM platform
implementation 'com.jsoizo:kotlin-csv-js:1.10.0' // for Kotlin JS platform
```

### Maven

```maven
<dependency>
<groupId>com.github.doyaaaaaken</groupId>
<groupId>com.jsoizo</groupId>
<artifactId>kotlin-csv-jvm</artifactId>
<version>1.9.3</version>
<version>1.10.0</version>
</dependency>
<dependency>
<groupId>com.github.doyaaaaaken</groupId>
<groupId>com.jsoizo</groupId>
<artifactId>kotlin-csv-js</artifactId>
<version>1.9.3</version>
<version>1.10.0</version>
</dependency>
```

### [kscript](https://github.com/holgerbrandl/kscript)

```kotlin
@file:DependsOn("com.github.doyaaaaaken:kotlin-csv-jvm:1.9.3") // for JVM platform
@file:DependsOn("com.github.doyaaaaaken:kotlin-csv-js:1.9.3") // for Kotlin JS platform
@file:DependsOn("com.jsoizo:kotlin-csv-jvm:1.10.0") // for JVM platform
@file:DependsOn("com.jsoizo:kotlin-csv-js:1.10.0") // for Kotlin JS platform
```

## Examples
Expand Down Expand Up @@ -115,7 +118,7 @@ csvReader().open("test1.csv") {
csvReader().open("test2.csv") {
readAllWithHeaderAsSequence().forEach { row: Map<String, String> ->
//Do something
println(row) //{id=1, name=doyaaaaaken}
println(row) //{id=1, name=jsoizo}
}
}
```
Expand Down Expand Up @@ -276,7 +279,7 @@ val writer = csvWriter {

**Documents**

* [Change Logs](https://github.com/doyaaaaaken/kotlin-csv/releases)
* [Change Logs](https://github.com/jsoizo/kotlin-csv/releases)

**Libraries which use kotlin-csv**

Expand All @@ -286,13 +289,13 @@ val writer = csvWriter {

## 🤝 Contributing

Contributions, [issues](https://github.com/doyaaaaaken/kotlin-csv/issues) and feature requests are welcome!
Contributions, [issues](https://github.com/jsoizo/kotlin-csv/issues) and feature requests are welcome!
If you have questions, ask away in [Kotlin Slack's](https://kotlinlang.slack.com) `kotlin-csv` room.

## 💻 Development

```sh
git clone git@github.com:doyaaaaaken/kotlin-csv.git
git clone git@github.com:jsoizo/kotlin-csv.git
cd kotlin-csv
./gradlew check
```
Expand Down
42 changes: 24 additions & 18 deletions build.gradle.kts
Original file line number Diff line number Diff line change
@@ -1,21 +1,23 @@
import org.jetbrains.kotlin.gradle.targets.js.dsl.ExperimentalWasmDsl

plugins {
java
kotlin("multiplatform") version "1.6.21"
id("org.jetbrains.dokka").version("1.6.21")
kotlin("multiplatform") version "2.1.10"
id("org.jetbrains.dokka").version("1.7.20")
`maven-publish`
signing
jacoco
}

group = "com.github.doyaaaaaken"
version = "1.9.3"
group = "com.jsoizo"
version = "1.10.0"

buildscript {
repositories {
mavenCentral()
}
dependencies {
classpath("org.jetbrains.dokka:dokka-gradle-plugin:1.6.21")
classpath("org.jetbrains.dokka:dokka-gradle-plugin:1.7.20")
}
}

Expand All @@ -38,15 +40,19 @@ kotlin {
artifact(dokkaJar)
}
}
js(BOTH) {
js(IR) {
browser {
}
nodejs {
}
}
@OptIn(ExperimentalWasmDsl::class)
wasmJs {
browser()
}
sourceSets {
val commonMain by getting
val commonTest by getting {
commonMain {}
commonTest {
dependencies {
implementation(kotlin("test-common"))
implementation(kotlin("test-annotations-common"))
Expand Down Expand Up @@ -87,26 +93,26 @@ publishing {
(this as MavenPublication).pom {
name.set("kotlin-csv")
description.set("Kotlin CSV Reader/Writer")
url.set("https://github.com/doyaaaaaken/kotlin-csv")
url.set("https://github.com/jsoizo/kotlin-csv")

organization {
name.set("com.github.doyaaaaaken")
url.set("https://github.com/doyaaaaaken")
name.set("com.jsoizo")
url.set("https://github.com/jsoizo")
}
licenses {
license {
name.set("Apache License 2.0")
url.set("https://github.com/doyaaaaaken/kotlin-csv/blob/master/LICENSE")
url.set("https://github.com/jsoizo/kotlin-csv/blob/master/LICENSE")
}
}
scm {
url.set("https://github.com/doyaaaaaken/kotlin-csv")
connection.set("scm:git:git://github.com/doyaaaaaken/kotlin-csv.git")
developerConnection.set("https://github.com/doyaaaaaken/kotlin-csv")
url.set("https://github.com/jsoizo/kotlin-csv")
connection.set("scm:git:git://github.com/jsoizo/kotlin-csv.git")
developerConnection.set("https://github.com/jsoizo/kotlin-csv")
}
developers {
developer {
name.set("doyaaaaaken")
name.set("jsoizo")
}
}
}
Expand Down Expand Up @@ -153,7 +159,7 @@ tasks.jacocoTestReport {
.setFrom(files("${buildDir}/jacoco/jvmTest.exec"))

reports {
xml.isEnabled = true
html.isEnabled = false
xml.required.set(true)
html.required.set(false)
}
}
Binary file modified gradle/wrapper/gradle-wrapper.jar
Binary file not shown.
2 changes: 1 addition & 1 deletion gradle/wrapper/gradle-wrapper.properties
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
distributionBase=GRADLE_USER_HOME
distributionPath=wrapper/dists
distributionUrl=https\://services.gradle.org/distributions/gradle-7.5.1-bin.zip
distributionUrl=https\://services.gradle.org/distributions/gradle-8.1-bin.zip
zipStoreBase=GRADLE_USER_HOME
zipStorePath=wrapper/dists
Loading