Hi All, when I create a folder/directory in my root directory to hold a new project and run hs auth to create a config file for it, it’s not creating one. I have already successfully run hs init and the config file is in the root directory. Could someone please explain how to fix that/what I might be doing wrong? Thanks for the help!
Hi @ALetaw ,
When you initially run hs init, you don’t need to run hs auth unless you are setting up a connection to a new portal. Init creates the config file and auth updates it with new permissions, so if you are just working in 1 portal, you don’t need to worry about ‘hs auth’.
Once you have run hs init, you are connected to the portal and can use any of the CLI commands to manage your folders / files between your local computer and the hubspot portal you are connected to.
Thank you for your reply. In the tutorials, it shows the config file in the folder that is created for the tutorial. I had the config file in the first one I did, but not on any of the subsequent ones. I also get an error when I try to run the watch command and have to use hs upload instead.
I sort of know command line but only just enough to not really understand when something doesn’t work. Thanks for your patience!
Thank you for your reply. And, I stand corrected. This is the “error” I receive when running: C:\xx\xxxxxx\annaberd>hs watch annaberd annaberd
[INFO] The “hs watch” command no longer uploads the watched directory when started. The directory “annaberd” was not uploaded. [INFO] To upload the directory run “hs upload” beforehand or add the “--initial-upload” option when running “hs watch”. Watcher is ready and watching C:\xx\xxxxxx\annaberd\annaberd. Any changes detected will be automatically uploaded and overwrite the current version in the developer file system.
So, [INFO] is different than [ERROR]. I was thrown by the first statement but the changes to the files are in fact uploading in real time.
The first time I set up the CLI, ran init and did the first tutorial, I did not get these [INFO] messages. Why am I getting them now?
I believe this is the expected behaviour when using hs watch.
I use it on a daily basis and I see the same [INFO] messages as you, so don’t worry about it. It’s just letting you know that by running hs watch you are not uploading content yet until you save your changes in your files. This is in case some people expect hs watch to deploy everything and then watch, which is not the case.
So, don’t worry about those messages, you are doing everything correctly