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

Commit4e03814

Browse files
committed
address PR comments
1 parent1638d3f commit4e03814

File tree

2 files changed

+25
-19
lines changed

2 files changed

+25
-19
lines changed

‎.github/workflows/traiage.yaml‎

Lines changed: 14 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -134,20 +134,20 @@ jobs:
134134
trap 'rm -f "${SUMMARY_FILE}"' EXIT
135135
AUTO_SUMMARY=$(./scripts/traiage.sh summary)
136136
{
137-
echo "## TrAIage Results";
138-
echo "- **Issue URL:** ${ISSUE_URL}";
139-
echo "- **Context Key:** ${CONTEXT_KEY}";
140-
echo "- **Workspace:** ${WORKSPACE_NAME}";
141-
echo "- **Archive URL:** ${ARCHIVE_URL}";
142-
echo "";
143-
echo "${AUTO_SUMMARY}";
144-
echo "";
145-
echo "To fetch the output to your own workspace:";
146-
echo '';
147-
echo '```bash';
148-
echo "BUCKET_PREFIX=${BUCKET_PREFIX} WORKSPACE_NAME=${WORKSPACE_NAME} ./scripts/traiage.sh resume";
149-
echo '```';
150-
echo ''
137+
echo "## TrAIage Results"
138+
echo "- **Issue URL:** ${ISSUE_URL}"
139+
echo "- **Context Key:** ${CONTEXT_KEY}"
140+
echo "- **Workspace:** ${WORKSPACE_NAME}"
141+
echo "- **Archive URL:** ${ARCHIVE_URL}"
142+
echo
143+
echo "${AUTO_SUMMARY}"
144+
echo
145+
echo "To fetch the output to your own workspace:"
146+
echo
147+
echo '```bash'
148+
echo "BUCKET_PREFIX=${BUCKET_PREFIX} WORKSPACE_NAME=${WORKSPACE_NAME} ./scripts/traiage.sh resume"
149+
echo '```'
150+
echo
151151
} >> "${SUMMARY_FILE}"
152152
153153
if [[ "${ISSUE_URL}" == "https://github.com/${GITHUB_REPOSITORY}"* ]]; then

‎scripts/traiage.sh‎

Lines changed: 11 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -25,10 +25,10 @@ create() {
2525
--url"${CODER_URL}" \
2626
--token"${CODER_SESSION_TOKEN}" \
2727
list \
28-
--search"owner:me name:${WORKSPACE_NAME}" \
28+
--search"owner:me" \
2929
--output json|
30-
jq -r'. | length')
31-
if [["${exists}"-eq"1" ]];then
30+
jq -r--arg name"${WORKSPACE_NAME}"'any(.[]; select(.name == $name))')
31+
if [["${exists}"-eq"true" ]];then
3232
echo"Workspace${WORKSPACE_NAME} already exists."
3333
exit 0
3434
fi
@@ -194,10 +194,16 @@ summary() {
194194
-- \
195195
bash<<-EOF
196196
#!/usr/bin/env bash
197-
set -euo pipefail
197+
set -eu
198198
summary=\$(echo -n 'You are a CLI utility that generates a human-readable Markdown summary for the currently staged AND unstaged changes. Print ONLY the summary and nothing else.' |\${HOME}/.local/bin/claude --print)
199199
if [[ -z "\${summary}" ]]; then
200-
summary="Generating a summary failed. Here is a short overview:\n\$(git diff --stat)"
200+
echo "Generating a summary failed."
201+
echo "Here is a short overview of the changes:"
202+
echo
203+
echo "$()$("
204+
echo"$(git diff --stat)"
205+
echo")$()"
206+
exit 0
201207
fi
202208
echo "\${summary}"
203209
exit 0

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp