Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

refactor: Flank scripts features not depends on each other #1572

Merged
Merged
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
2 changes: 1 addition & 1 deletion flank-scripts/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ shadowJar.apply {
}
}
// <breaking change>.<feature added>.<fix/minor change>
version = "1.5.1"
version = "1.5.2"
group = "com.github.flank"

application {
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
package flank.scripts.cli.shell

import com.github.ajalt.clikt.core.CliktCommand
import flank.scripts.ops.shell.ios.buildFtl
import flank.scripts.ops.shell.buildexample.ios.buildFtl

object BuildFtlCommand : CliktCommand(
name = "iosBuildFtl",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ package flank.scripts.cli.shell
import com.github.ajalt.clikt.core.CliktCommand
import com.github.ajalt.clikt.parameters.options.option
import com.github.ajalt.clikt.parameters.options.required
import flank.scripts.ops.shell.ios.runFtlLocal
import flank.scripts.ops.shell.buildexample.ios.runFtlLocal

object RunFtlLocalCommand : CliktCommand(
name = "iosRunFtlLocal",
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
package flank.scripts.cli.shell

import com.github.ajalt.clikt.core.CliktCommand
import flank.scripts.ops.shell.ios.createUniversalFrameworkFiles
import flank.scripts.ops.shell.buildexample.ios.createUniversalFrameworkFiles

object UniversalFrameworkCommand : CliktCommand(
name = "iosUniversalFramework",
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
package flank.scripts.cli.shell.buildexample

import com.github.ajalt.clikt.core.CliktCommand
import flank.scripts.ops.shell.ios.buildIosExample
import flank.scripts.ops.shell.buildexample.ios.buildIosExample

object BuildExampleCommand : CliktCommand(
name = "iosBuildExample",
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,8 @@
package flank.scripts.ops.ci.releasenotes
package flank.scripts.ops.ci

import flank.common.withNewLineAtTheEnd
import flank.scripts.ops.common.ReleaseNotesWithType
import flank.scripts.ops.common.asString
import java.io.File

fun File.appendReleaseNotes(releaseNotesWithType: ReleaseNotesWithType, releaseTag: String) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,7 @@ package flank.scripts.ops.ci
import com.github.kittinunf.result.map
import com.github.kittinunf.result.success
import flank.scripts.data.github.getLatestReleaseTag
import flank.scripts.ops.ci.releasenotes.appendReleaseNotes
import flank.scripts.ops.ci.releasenotes.generateReleaseNotes
import flank.scripts.ops.common.generateReleaseNotes
import kotlinx.coroutines.runBlocking
import java.io.File

Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
package flank.scripts.ops.ci.releasenotes
package flank.scripts.ops.common

fun String.mapPrTitleWithType() = when {
startsWith("feat") -> "Features" to skipConventionalCommitPrefix().capitalize()
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
package flank.scripts.ops.shell.buildexample.ios
package flank.scripts.ops.common

const val EARL_GREY_EXAMPLE = "EarlGreyExample"
const val EARL_GREY_EXAMPLE_TESTS = "EarlGreyExampleTests"
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
package flank.scripts.ops.ci.releasenotes
package flank.scripts.ops.common

import com.github.kittinunf.result.Result
import com.github.kittinunf.result.getOrElse
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
package flank.scripts.ops.ci.releasenotes
package flank.scripts.ops.common

import flank.scripts.utils.markdownH2
import flank.scripts.utils.markdownH3
Expand Down
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
package flank.scripts.ops.release.hub

import com.google.common.annotations.VisibleForTesting
import flank.scripts.ops.ci.releasenotes.asString
import flank.scripts.ops.ci.releasenotes.generateReleaseNotes
import flank.scripts.ops.common.asString
import flank.scripts.ops.common.generateReleaseNotes
import flank.scripts.utils.ERROR_WHEN_RUNNING
import flank.scripts.utils.runCommand
import java.io.File
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
package flank.scripts.ops.shell

import flank.common.iOSTestProjectsPath
import flank.scripts.ops.shell.buildexample.ios.EARL_GREY_EXAMPLE
import flank.scripts.ops.common.EARL_GREY_EXAMPLE
import flank.scripts.utils.downloadCocoaPodsIfNeeded
import flank.scripts.utils.failIfWindows
import flank.scripts.utils.installPodsIfNeeded
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,9 @@
package flank.scripts.ops.shell.buildexample.ios

import flank.common.iOSTestProjectsPath
import flank.scripts.ops.common.EARL_GREY_EXAMPLE
import flank.scripts.ops.common.EARL_GREY_EXAMPLE_SWIFT_TESTS
import flank.scripts.ops.common.EARL_GREY_EXAMPLE_TESTS
import flank.scripts.utils.failIfWindows
import java.nio.file.Paths

Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
package flank.scripts.ops.shell.ios
package flank.scripts.ops.shell.buildexample.ios

import flank.common.archive
import flank.common.currentPath
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
package flank.scripts.ops.shell.ios
package flank.scripts.ops.shell.buildexample.ios

import flank.common.archive
import flank.scripts.utils.downloadXcPrettyIfNeeded
Expand Down
Original file line number Diff line number Diff line change
@@ -1,8 +1,6 @@
package flank.scripts.ops.shell.buildexample.ios

import flank.common.flankFixturesIosTmpPath
import flank.scripts.ops.shell.ios.createXcodeArchiveCommand
import flank.scripts.ops.shell.ios.createXcodeExportArchiveCommand
import flank.scripts.utils.downloadCocoaPodsIfNeeded
import flank.scripts.utils.downloadXcPrettyIfNeeded
import flank.scripts.utils.installPodsIfNeeded
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@ package flank.scripts.ops.shell.buildexample.ios

import flank.common.archive
import flank.common.flankFixturesIosTmpPath
import flank.scripts.ops.shell.ios.createXcodeBuildForTestingCommand
import flank.scripts.utils.downloadCocoaPodsIfNeeded
import flank.scripts.utils.downloadXcPrettyIfNeeded
import flank.scripts.utils.installPodsIfNeeded
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
package flank.scripts.ops.shell.ios
package flank.scripts.ops.shell.buildexample.ios

fun createXcodeBuildForTestingCommand(
buildDir: String,
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
package flank.scripts.ops.shell.ios
package flank.scripts.ops.shell.buildexample.ios

fun createLipoCommand(
outputPath: String,
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
package flank.scripts.ops.shell.ios
package flank.scripts.ops.shell.buildexample.ios

import flank.common.currentPath
import flank.scripts.utils.failIfWindows
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
package flank.scripts.ops.shell.ios
package flank.scripts.ops.shell.buildexample.ios

import flank.common.currentPath
import flank.scripts.utils.failIfWindows
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
package flank.scripts.ops.ci.releasenotes

import com.google.common.truth.Truth.assertThat
import flank.scripts.ops.ci.appendReleaseNotes
import flank.scripts.utils.markdownH2
import flank.scripts.utils.markdownH3
import org.junit.Test
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
package flank.scripts.ops.ci.releasenotes

import com.google.common.truth.Truth.assertThat
import flank.scripts.ops.common.mapPrTitleWithType
import org.junit.Test
import org.junit.runner.RunWith
import org.junit.runners.Parameterized
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
package flank.scripts.ops.ci.releasenotes

import flank.scripts.ops.common.asString
import org.junit.Assert.assertEquals
import org.junit.Test

Expand Down