mirror of
https://github.com/actions/deploy-pages.git
synced 2026-03-28 17:04:53 +00:00
Compare commits
13 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
eaf36f48c9 | ||
|
|
01f6ae5af2 | ||
|
|
82cb77089c | ||
|
|
ad36b7023a | ||
|
|
32b8b86ff0 | ||
|
|
a598b2af14 | ||
|
|
f511fa4665 | ||
|
|
0e157789db | ||
|
|
12940a5b99 | ||
|
|
6afc4f2884 | ||
|
|
7a1dc4e394 | ||
|
|
92f6725bee | ||
|
|
e1279a88ef |
@@ -3,8 +3,10 @@ description: 'A GitHub Action to deploy an artifact to GitHub Pages'
|
|||||||
runs:
|
runs:
|
||||||
using: 'node16'
|
using: 'node16'
|
||||||
main: 'dist/index.js'
|
main: 'dist/index.js'
|
||||||
pre: 'pre/index.js'
|
|
||||||
inputs:
|
inputs:
|
||||||
|
emit_telemetry:
|
||||||
|
description: 'Should this action only emit build telemetry instead of deploying the build artifact?'
|
||||||
|
required: false
|
||||||
token:
|
token:
|
||||||
description: 'GitHub token'
|
description: 'GitHub token'
|
||||||
default: ${{ github.token }}
|
default: ${{ github.token }}
|
||||||
@@ -20,7 +22,7 @@ inputs:
|
|||||||
reporting_interval:
|
reporting_interval:
|
||||||
description: 'Time in milliseconds between two deployment status report (default: 1 second)'
|
description: 'Time in milliseconds between two deployment status report (default: 1 second)'
|
||||||
required: false
|
required: false
|
||||||
default: "1000"
|
default: "5000"
|
||||||
outputs:
|
outputs:
|
||||||
page_url:
|
page_url:
|
||||||
description: 'URL to deployed Github Pages'
|
description: 'URL to deployed Github Pages'
|
||||||
|
|||||||
11
dist/index.js
vendored
11
dist/index.js
vendored
@@ -7182,13 +7182,14 @@ class Deployment {
|
|||||||
core.setFailed('Failed with status code: ' + res.status)
|
core.setFailed('Failed with status code: ' + res.status)
|
||||||
break
|
break
|
||||||
}
|
}
|
||||||
}
|
|
||||||
// Handle timeout
|
// Handle timeout
|
||||||
if (Date.now() - startTime >= timeout) {
|
if (Date.now() - startTime >= timeout) {
|
||||||
core.info('Timeout reached, aborting!')
|
core.info('Timeout reached, aborting!')
|
||||||
core.setFailed('Timeout reached, aborting!')
|
core.setFailed('Timeout reached, aborting!')
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
|
}
|
||||||
} catch (error) {
|
} catch (error) {
|
||||||
core.setFailed(error)
|
core.setFailed(error)
|
||||||
if (error.response && error.response.data) {
|
if (error.response && error.response.data) {
|
||||||
@@ -7472,7 +7473,15 @@ process.on('SIGINT', cancelHandler)
|
|||||||
process.on('SIGTERM', cancelHandler)
|
process.on('SIGTERM', cancelHandler)
|
||||||
|
|
||||||
// Main
|
// Main
|
||||||
|
const emitTelemetry = core.getInput("emit_telemetry")
|
||||||
|
if (emitTelemetry === "true") {
|
||||||
|
__nccwpck_require__(9557)
|
||||||
|
} else if (emitTelemetry === "false") {
|
||||||
|
main()
|
||||||
|
} else {
|
||||||
|
// If emit_telemetry is not set, that indicates an older version of the dynamic workflow that doesn't separate telemetry from deployment
|
||||||
main().then(() => __nccwpck_require__(9557))
|
main().then(() => __nccwpck_require__(9557))
|
||||||
|
}
|
||||||
|
|
||||||
})();
|
})();
|
||||||
|
|
||||||
|
|||||||
2
dist/index.js.map
vendored
2
dist/index.js.map
vendored
File diff suppressed because one or more lines are too long
@@ -7182,13 +7182,14 @@ class Deployment {
|
|||||||
core.setFailed('Failed with status code: ' + res.status)
|
core.setFailed('Failed with status code: ' + res.status)
|
||||||
break
|
break
|
||||||
}
|
}
|
||||||
}
|
|
||||||
// Handle timeout
|
// Handle timeout
|
||||||
if (Date.now() - startTime >= timeout) {
|
if (Date.now() - startTime >= timeout) {
|
||||||
core.info('Timeout reached, aborting!')
|
core.info('Timeout reached, aborting!')
|
||||||
core.setFailed('Timeout reached, aborting!')
|
core.setFailed('Timeout reached, aborting!')
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
|
}
|
||||||
} catch (error) {
|
} catch (error) {
|
||||||
core.setFailed(error)
|
core.setFailed(error)
|
||||||
if (error.response && error.response.data) {
|
if (error.response && error.response.data) {
|
||||||
|
|||||||
File diff suppressed because one or more lines are too long
@@ -138,13 +138,14 @@ class Deployment {
|
|||||||
core.setFailed('Failed with status code: ' + res.status)
|
core.setFailed('Failed with status code: ' + res.status)
|
||||||
break
|
break
|
||||||
}
|
}
|
||||||
}
|
|
||||||
// Handle timeout
|
// Handle timeout
|
||||||
if (Date.now() - startTime >= timeout) {
|
if (Date.now() - startTime >= timeout) {
|
||||||
core.info('Timeout reached, aborting!')
|
core.info('Timeout reached, aborting!')
|
||||||
core.setFailed('Timeout reached, aborting!')
|
core.setFailed('Timeout reached, aborting!')
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
|
}
|
||||||
} catch (error) {
|
} catch (error) {
|
||||||
core.setFailed(error)
|
core.setFailed(error)
|
||||||
if (error.response && error.response.data) {
|
if (error.response && error.response.data) {
|
||||||
|
|||||||
@@ -52,4 +52,12 @@ process.on('SIGINT', cancelHandler)
|
|||||||
process.on('SIGTERM', cancelHandler)
|
process.on('SIGTERM', cancelHandler)
|
||||||
|
|
||||||
// Main
|
// Main
|
||||||
|
const emitTelemetry = core.getInput("emit_telemetry")
|
||||||
|
if (emitTelemetry === "true") {
|
||||||
|
require('./pre')
|
||||||
|
} else if (emitTelemetry === "false") {
|
||||||
|
main()
|
||||||
|
} else {
|
||||||
|
// If emit_telemetry is not set, that indicates an older version of the dynamic workflow that doesn't separate telemetry from deployment
|
||||||
main().then(() => require('./pre'))
|
main().then(() => require('./pre'))
|
||||||
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user