code-theme-converter icon indicating copy to clipboard operation
code-theme-converter copied to clipboard

code2idea and code2subl are not able to checkout the repo

Open charitarthchugh opened this issue 3 years ago • 5 comments

Here is the following error output:

~
❯ code2idea https://github.com/piousdeer/vscode-adwaita.git
Fetching repo
Trace: Error: 'git checkout' failed with status 1
    at Object.<anonymous> (/home/user/.npm/lib/node_modules/code-theme-converter/dist/idea/convert.js:88:21)
    at Generator.throw (<anonymous>)
    at rejected (/home/user/.npm/lib/node_modules/code-theme-converter/dist/idea/convert.js:6:65)
  Successfully converted the vscode theme for IDEA!

Same for code2subl

❯ code2subl "https://github.com/piousdeer/vscode-adwaita"
Fetching repo
Error: 'git checkout' failed with status 1
Successfully converted the vscode theme for sublime text!

Tested against node 18.3.0 and 16.15.1 I have been able to reproduce this behavior in a container as well (node:latest & node:16)

charitarthchugh avatar Jun 08 '22 14:06 charitarthchugh

Try again using code2subl https://github.com/piousdeer/vscode-adwaita#main instead. Works for me!

agenordebriat avatar Jun 13 '22 08:06 agenordebriat

Worked for me as well with code2idea. I am guessing this behavior is due to explicitly looking for the master branch as the default?

charitarthchugh avatar Jun 13 '22 08:06 charitarthchugh

Yup.

agenordebriat avatar Jun 13 '22 08:06 agenordebriat

Yeah I didn't have the time to introduce any changes in the last year. Probably there needs to be a check for master/main

tobiastimm avatar Dec 07 '23 10:12 tobiastimm