Open cameronpickham opened 5 years ago
I tried this and couldn't get it work. I poked around the dev-cli and config source and can't find a way to do it.
baseDir
is used only to create the manifest but not used for publish.
I had to redefine the whole oclif.update.s3.templates
config :
"update": {
"s3": {
"bucket": "devbucket",
"templates": {
"target": {
"baseDir": "my-cli/<%- bin %>",
"unversioned": "my-cli/<%- channel === 'stable' ? '' : 'channels/' + channel + '/' %><%- bin %>-<%- platform %>-<%- arch %><%- ext %>",
"versioned": "my-cli/<%- channel === 'stable' ? '' : 'channels/' + channel + '/' %><%- bin %>-v<%- version %>/<%- bin %>-v<%- version %>-<%- platform %>-<%- arch %><%- ext %>",
"manifest": "my-cli/<%- channel === 'stable' ? '' : 'channels/' + channel + '/' %><%- platform %>-<%- arch %>"
},
"vanilla": {
"baseDir": "my-cli/<%- bin %>",
"unversioned": "my-cli/<%- channel === 'stable' ? '' : 'channels/' + channel + '/' %><%- bin %>-<%- platform %>-<%- arch %><%- ext %>",
"versioned": "my-cli/<%- channel === 'stable' ? '' : 'channels/' + channel + '/' %><%- bin %>-v<%- version %>/<%- bin %>-v<%- version %>-<%- platform %>-<%- arch %><%- ext %>",
"manifest": "my-cli/<%- channel === 'stable' ? '' : 'channels/' + channel + '/' %><%- platform %>-<%- arch %>"
}
}
}
}
Another workaround is to set the path inside S3 bucket key...
"update": {
"s3": {
"bucket": "devbucket/my-cli"
}
}
It publish files inside the folder. but generated version
file is wrong.
@oclif/dev-cli/1.22.2 linux-x64 node-v10.16.3
I'm able to specify a bucket, but it would be nice if I could namespace it so that my bucket can be more organized.
Currently-generated location: s3://mybucket/channels/alpha/mycli-v1.0.0-alpha.1/mycli-v1.0.0-alpha.1-linux-x64.tar.gz
Desired location: s3://mybucket/mycli/channels/alpha/mycli-v1.0.0-alpha.1/mycli-v1.0.0-alpha.1-linux-x64.tar.gz