Skip to content

Commit

Permalink
Merge pull request #26 from tuftsceeo/dev/nick
Browse files Browse the repository at this point in the history
Update release-render-pipeline.yml
  • Loading branch information
NicK4rT authored Dec 4, 2024
2 parents fb421a8 + 5a8b667 commit 77f1953
Showing 1 changed file with 19 additions and 19 deletions.
38 changes: 19 additions & 19 deletions .github/workflows/release-render-pipeline.yml
Original file line number Diff line number Diff line change
Expand Up @@ -76,25 +76,25 @@ jobs:
if echo "$all_changed_files" | grep -q "$base_file"; then
# Use Python to update the version
python3 - <<EOF
import ast
config_path = 'software/release/config.py'
with open(config_path, 'r') as f:
version = ast.literal_eval(f.read().strip().split('= ', 1)[1])
if '$base_file' in version:
version['$base_file'] += 1
print(f"Updated $base_file version to {version['$base_file']}")
else:
version['$base_file'] = 1
print(f"Added $base_file with version 1")
with open(config_path, 'w') as f:
f.write(f"version = {repr(version)}")
EOF
else
echo "No change detected for $base_file"
fi
done < file_list.txt
import ast
config_path = 'software/release/config.py'
with open(config_path, 'r') as f:
version = ast.literal_eval(f.read().strip().split('= ', 1)[1])

if '$base_file' in version:
version['$base_file'] += 1
print(f"Updated $base_file version to {version['$base_file']}")
else:
version['$base_file'] = 1
print(f"Added $base_file with version 1")

with open(config_path, 'w') as f:
f.write(f"version = {repr(version)}")
EOF
else
echo "No change detected for $base_file"
fi
done < file_list.txt

# --- Step 3: Render README.qmd to Markdown ---
- name: Set up R
Expand Down

0 comments on commit 77f1953

Please sign in to comment.