Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commite810230

Browse files
committed
fix: update cron field schema description and fix formatting
- Updated the cron field description in provider/script.go to include detailed 6-field format explanation- Fixed formatting issues in documentation (removed extra spaces before comments)- Regenerated documentation to ensure consistency between schema and docs- This ensures the documentation generation preserves the detailed cron description instead of reverting to generic text
1 parentc9c5733 commite810230

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

‎docs/resources/script.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -47,7 +47,7 @@ resource "coder_script" "nightly_update" {
4747
agent_id = coder_agent.dev.agent_id
4848
display_name = "Nightly update"
4949
icon = "/icon/database.svg"
50-
cron = "0 0 22 * * *"# Run at 22:00 (10 PM) every day
50+
cron = "0 0 22 * * *" # Run at 22:00 (10 PM) every day
5151
script = <<EOF
5252
#!/bin/sh
5353
echo "Running nightly update"
@@ -59,7 +59,7 @@ resource "coder_script" "every_5_minutes" {
5959
agent_id = coder_agent.dev.agent_id
6060
display_name = "Health check"
6161
icon = "/icon/heart.svg"
62-
cron = "0 */5 * * * *"# Run every 5 minutes
62+
cron = "0 */5 * * * *" # Run every 5 minutes
6363
script = <<EOF
6464
#!/bin/sh
6565
echo "Health check at $(date)"

‎provider/script.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -99,7 +99,7 @@ func scriptResource() *schema.Resource {
9999
ForceNew:true,
100100
Type:schema.TypeString,
101101
Optional:true,
102-
Description:"The cron schedule to run the script on. Thisis a cron expression.",
102+
Description:"The cron schedule to run the script on. Thisuses a6-fieldcron expression format: `seconds minutes hours day-of-month month day-of-week`. Note that this differs from the standard Unix 5-field format by including seconds as the first field. Examples: `\"0 0 22 * * *\"` (daily at 10 PM), `\"0 */5 * * * *\"` (every 5 minutes), `\"30 0 9 * * 1-5\"` (weekdays at 9:30 AM).",
103103
ValidateFunc:func(iinterface{},_string) ([]string, []error) {
104104
v,ok:=i.(string)
105105
if!ok {

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp