Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Auto release upon edit to CITATION.cff #124

Merged
merged 4 commits into from
Dec 12, 2024
Merged

Auto release upon edit to CITATION.cff #124

merged 4 commits into from
Dec 12, 2024

Conversation

hdashnow
Copy link
Member

Credit to @vincerubinetti for doing most of the work here. I just updated some file naming/matching

Copy link

netlify bot commented Dec 11, 2024

Deploy Preview for strchive ready!

Name Link
🔨 Latest commit 74602b7
🔍 Latest deploy log https://app.netlify.com/sites/strchive/deploys/675a19247e0a220008303a8f
😎 Deploy Preview https://deploy-preview-124--strchive.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify site configuration.

@vincerubinetti vincerubinetti linked an issue Dec 11, 2024 that may be closed by this pull request
@hdashnow
Copy link
Member Author

This was my easiest CI debug ever 😂
Screenshot 2024-12-11 at 11 24 35 AM

for (const file of globSync("**/STRchive-*.json"))
renameSync(file, file.replace(".json", `_v${newVersion}.json`));
for (const file of globSync("**/*STRchive-disease-loci*.bed"))
renameSync(file, file.replace("-loci", `-loci_v${newVersion}`));
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

If you're going to keep the file names as they are, I'd change the _ to a . to be consistent with the other separators. As it is right now, it'd become e.g. T2T-chm13.STRchive-disease-loci_v2.1.0.TRGT.bed.

Ideally though, unless you don't want to make breaking changes or the current format is some kind of convention, I'd recommend renaming the files to e.g. STRchive-disease-loci_v2.1.0_T2T-chm13_TRGT.bed. To me that's more readable, understandable, and easily parsable with code, and will also group them together more nicely in alphabetical (most) file system views.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for the reminder about file names @vincerubinetti
What about something like this?

File names in github:

STRchive-citations-test.json			
STRchive-citations.json				
STRchive-disease-loci.T2T-chm13.TRGT.bed
STRchive-disease-loci.T2T-chm13.bed
STRchive-disease-loci.hg19.TRGT.bed
STRchive-disease-loci.hg19.bed
STRchive-disease-loci.hg38.TRGT.bed
STRchive-disease-loci.hg38.bed
STRchive-loci.json

renaming:

            // add version to artifact filenames
            for (const file of globSync("**/STRchive-*.json"))
              renameSync(file, file.replace("STRchive", `STRchive_v${newVersion}`));
            for (const file of globSync("**/*STRchive-disease-loci*.bed"))
              renameSync(file, file.replace("STRchive", `STRchive_v${newVersion}`));
              

Which would produce:
STRchive_v2.0.0-disease-loci.hg38.bed

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

That looks better to me, though I'd still replace the _ with a .

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

To be clear, I just mean that I'd be consistent with group vs. part separators. E.g.:

STRchive-v2.0.0-disease-loci.hg38.bed or STRchive.v2.0.0.disease-loci.hg38.bed or STRchive_v2.0.0_disease-loci_hg38.bed

@hdashnow
Copy link
Member Author

hdashnow commented Dec 11, 2024

Updated with more consistent naming and tested that all the scripts still work and I didn't break anything when I changed names.

@hdashnow
Copy link
Member Author

@vincerubinetti any additional feedback?

@hdashnow hdashnow merged commit bfbadf3 into main Dec 12, 2024
2 checks passed
@hdashnow hdashnow deleted the release branch December 12, 2024 19:52
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Set up CI
2 participants