Skip to content

Commit

Permalink
feat(actions): add peaceiris/actions-hugo@v3
Browse files Browse the repository at this point in the history
  • Loading branch information
krzema12 committed Apr 11, 2024
1 parent dc92328 commit cfb7a54
Show file tree
Hide file tree
Showing 5 changed files with 84 additions and 2 deletions.
Empty file.
1 change: 1 addition & 0 deletions actions/peaceiris/actions-hugo/v3/commit-hash.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
75d2e84710de30f6ff7268e08f310b60ef14033f
4 changes: 2 additions & 2 deletions docs/supported-actions.md
Original file line number Diff line number Diff line change
Expand Up @@ -111,7 +111,7 @@ Click on a version to see the binding's code.
* [discord-webhook](https://github.com/nobrayner/discord-webhook) - v1: [`DiscordWebhookV1`](https://github.com/typesafegithub/github-workflows-kt/blob/v[[ version ]]/github-workflows-kt/src/gen/kotlin/io/github/typesafegithub/workflows/actions/nobrayner/DiscordWebhookV1.kt)
* peaceiris
* [actions-gh-pages](https://github.com/peaceiris/actions-gh-pages) - v3: [`ActionsGhPagesV3`](https://github.com/typesafegithub/github-workflows-kt/blob/v[[ version ]]/github-workflows-kt/src/gen/kotlin/io/github/typesafegithub/workflows/actions/peaceiris/ActionsGhPagesV3.kt), v4: [`ActionsGhPagesV4`](https://github.com/typesafegithub/github-workflows-kt/blob/v[[ version ]]/github-workflows-kt/src/gen/kotlin/io/github/typesafegithub/workflows/actions/peaceiris/ActionsGhPagesV4.kt)
* [actions-hugo](https://github.com/peaceiris/actions-hugo) - v2: [`ActionsHugoV2`](https://github.com/typesafegithub/github-workflows-kt/blob/v[[ version ]]/github-workflows-kt/src/gen/kotlin/io/github/typesafegithub/workflows/actions/peaceiris/ActionsHugoV2.kt)
* [actions-hugo](https://github.com/peaceiris/actions-hugo) - v2: [`ActionsHugoV2`](https://github.com/typesafegithub/github-workflows-kt/blob/v[[ version ]]/github-workflows-kt/src/gen/kotlin/io/github/typesafegithub/workflows/actions/peaceiris/ActionsHugoV2.kt), v3: [`ActionsHugoV3`](https://github.com/typesafegithub/github-workflows-kt/blob/v[[ version ]]/github-workflows-kt/src/gen/kotlin/io/github/typesafegithub/workflows/actions/peaceiris/ActionsHugoV3.kt)
* peter-evans
* [create-issue-from-file](https://github.com/peter-evans/create-issue-from-file) - v4: [`CreateIssueFromFileV4`](https://github.com/typesafegithub/github-workflows-kt/blob/v[[ version ]]/github-workflows-kt/src/gen/kotlin/io/github/typesafegithub/workflows/actions/peterevans/CreateIssueFromFileV4.kt), v5: [`CreateIssueFromFileV5`](https://github.com/typesafegithub/github-workflows-kt/blob/v[[ version ]]/github-workflows-kt/src/gen/kotlin/io/github/typesafegithub/workflows/actions/peterevans/CreateIssueFromFileV5.kt)
* [create-pull-request](https://github.com/peter-evans/create-pull-request) - v4: [`CreatePullRequestV4`](https://github.com/typesafegithub/github-workflows-kt/blob/v[[ version ]]/github-workflows-kt/src/gen/kotlin/io/github/typesafegithub/workflows/actions/peterevans/CreatePullRequestV4.kt), v5: [`CreatePullRequestV5`](https://github.com/typesafegithub/github-workflows-kt/blob/v[[ version ]]/github-workflows-kt/src/gen/kotlin/io/github/typesafegithub/workflows/actions/peterevans/CreatePullRequestV5.kt), v6: [`CreatePullRequestV6`](https://github.com/typesafegithub/github-workflows-kt/blob/v[[ version ]]/github-workflows-kt/src/gen/kotlin/io/github/typesafegithub/workflows/actions/peterevans/CreatePullRequestV6.kt)
Expand Down Expand Up @@ -141,6 +141,6 @@ Click on a version to see the binding's code.
Number of bindings available:

* counting by actions: 85
* counting each version separately: 163
* counting each version separately: 164

Actions [providing typings](https://github.com/typesafegithub/github-actions-typing/) (marked with ✅ on the above list): 18
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@
@file:Suppress(
"DataClassPrivateConstructor",
"UNUSED_PARAMETER",
"DEPRECATION",
)

package io.github.typesafegithub.workflows.actions.peaceiris
Expand All @@ -12,6 +13,7 @@ import io.github.typesafegithub.workflows.domain.actions.Action
import io.github.typesafegithub.workflows.domain.actions.RegularAction
import java.util.LinkedHashMap
import kotlin.Boolean
import kotlin.Deprecated
import kotlin.String
import kotlin.Suppress
import kotlin.Unit
Expand All @@ -34,6 +36,10 @@ import kotlin.collections.toTypedArray
* @param _customVersion Allows overriding action's version, for example to use a specific minor
* version, or a newer version that the binding doesn't yet know about
*/
@Deprecated(
message = "This action has a newer major version: ActionsHugoV3",
replaceWith = ReplaceWith("ActionsHugoV3"),
)
public data class ActionsHugoV2 private constructor(
/**
* The Hugo version to download (if necessary) and use. Example: 0.58.2
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,75 @@
// This file was generated using action-binding-generator. Don't change it by hand, otherwise your
// changes will be overwritten with the next binding code regeneration.
// See https://github.com/typesafegithub/github-workflows-kt for more info.
@file:Suppress(
"DataClassPrivateConstructor",
"UNUSED_PARAMETER",
)

package io.github.typesafegithub.workflows.actions.peaceiris

import io.github.typesafegithub.workflows.domain.actions.Action
import io.github.typesafegithub.workflows.domain.actions.RegularAction
import java.util.LinkedHashMap
import kotlin.Boolean
import kotlin.String
import kotlin.Suppress
import kotlin.Unit
import kotlin.collections.Map
import kotlin.collections.toList
import kotlin.collections.toTypedArray

/**
* Action: Hugo setup
*
* GitHub Actions for Hugo ⚡️ Setup Hugo quickly and build your site fast. Hugo extended and Hugo
* Modules are supported.
*
* [Action on GitHub](https://github.com/peaceiris/actions-hugo)
*
* @param hugoVersion The Hugo version to download (if necessary) and use. Example: 0.58.2
* @param extended Download (if necessary) and use Hugo extended version. Example: true
* @param _customInputs Type-unsafe map where you can put any inputs that are not yet supported by
* the binding
* @param _customVersion Allows overriding action's version, for example to use a specific minor
* version, or a newer version that the binding doesn't yet know about
*/
public data class ActionsHugoV3 private constructor(
/**
* The Hugo version to download (if necessary) and use. Example: 0.58.2
*/
public val hugoVersion: String? = null,
/**
* Download (if necessary) and use Hugo extended version. Example: true
*/
public val extended: Boolean? = null,
/**
* Type-unsafe map where you can put any inputs that are not yet supported by the binding
*/
public val _customInputs: Map<String, String> = mapOf(),
/**
* Allows overriding action's version, for example to use a specific minor version, or a newer
* version that the binding doesn't yet know about
*/
public val _customVersion: String? = null,
) : RegularAction<Action.Outputs>("peaceiris", "actions-hugo", _customVersion ?: "v3") {
public constructor(
vararg pleaseUseNamedArguments: Unit,
hugoVersion: String? = null,
extended: Boolean? = null,
_customInputs: Map<String, String> = mapOf(),
_customVersion: String? = null,
) : this(hugoVersion=hugoVersion, extended=extended, _customInputs=_customInputs,
_customVersion=_customVersion)

@Suppress("SpreadOperator")
override fun toYamlArguments(): LinkedHashMap<String, String> = linkedMapOf(
*listOfNotNull(
hugoVersion?.let { "hugo-version" to it },
extended?.let { "extended" to it.toString() },
*_customInputs.toList().toTypedArray(),
).toTypedArray()
)

override fun buildOutputObject(stepId: String): Action.Outputs = Outputs(stepId)
}

0 comments on commit cfb7a54

Please sign in to comment.