disintar / toncli

TON Command Line Interface - easy smart contract manipulation
https://disintar.io/
Apache License 2.0
156 stars 35 forks source link

Add `func build` absolute path support #15

Open psydvl opened 2 years ago

psydvl commented 2 years ago

Steps to reproduce:

mkdir -p ~/work/toncli-test/
touch ~/work/toncli-test/test.fc
cd ~/work/toncli-test/
toncli func build ~/work/toncli-test/test.fc

Expected behavior:

INFO: 🥌 Build ['/home/user/work/toncli-test/test.fc'] successfully, check out .test.fif

What we got now:

fatal: cannot open source file /home/user/work/toncli-test/home/user/work/toncli-test/test.fc
Traceback [bla-bla-bla]
tvorogme commented 2 years ago

Ok, ~ is not like absolute path. toncli build supports absolute from /. But! this is good idea, will add.

psydvl commented 2 years ago

As I know ~ unpacked by almost all shells before being sent to command, so there are no difference However, in "Steps to reproduce" you can replace ~ with homedir or $HOME without any change of result