waldronlab / bugsigdbr

R-side access to published microbial signatures from BugSigDB
https://bioconductor.org/packages/bugsigdbr
GNU General Public License v3.0
4 stars 2 forks source link

version should accept full SHA #41

Closed lwaldron closed 1 year ago

lwaldron commented 1 year ago

It currently only accepts a 7-character abbreviated SHA, which means that the full SHA that GitHub provides a copy tool for doesn't work:

image

The abbreviated SHA is just the first 7 characters of the full SHA, so there's no reason not to accept the full SHA. The above screenshot or instructions would also be helpful to add to the documentation, ie:

"Go to https://github.com/waldronlab/BugSigDBExports/commits/main and use the copy symbol to the left of the 7-character codes to copy the SHA code of the export version you want to use. "

(just came up because I was explaining to a user how to select a version and neither of us found it evident from ?importBugSigDB).

lgeistlinger commented 1 year ago

I didn't think it would be so difficult to copy and paste the short SHA from the commits page (or just type the 7 chars), but it is convenient to also be able to provide the full SHA. This is now supported as of bugsigdbr v1.7.2:

> library(bugsigdbr)
> df <- importBugSigDB(version = "ef9aea13fe765501d6aa625a61992e70972d00ec")
  |======================================================================| 100%
> df2 <- importBugSigDB(version = "ef9aea1", cache = FALSE)
  |======================================================================| 100%
> identical(df, df2)
[1] TRUE

This is also documented in ?importBugSigDB as part of #39.