Could anyone help me with this?
f = http.get("https://gitlab.com/api/v4/projects/22651806/repository/files/system%%2Fcload.lua/raw?ref=master&access_token=acz8QUbxQaFbekX-ARty&path=startupcl.lua")
print(f.readAll())
f.close()
it errors at f is nil
It works in the browser but why not in Lua?
The link didn't work in my browser, is it posible that your browser is also using it's cookies to make the link work?
It seems that it gives me a 400 bad request error. Gitlab might just be having issues
Are you sure that you are getting the raw URL right?
It looks like this
https://gitlab.com/hbomb79/Titanium/-/blob/develop/src/loadFirst.cfg
should turn into this
https://gitlab.com/hbomb79/Titanium/-/raw/develop/src/loadFirst.cfg
I've already included a gitlab tip repository for you that is in the group. Check for where it says "Gitlab Tips".
Quote from: eli310 on Jan 18, 2021, 02:45 AMCould anyone help me with this?
f = http.get("https://gitlab.com/api/v4/projects/22651806/repository/files/system%%2Fcload.lua/raw?ref=master&access_token=acz8QUbxQaFbekX-ARty&path=startupcl.lua")
print(f.readAll())
f.close()
it errors at f is nil
It shows that it got the files, but created the directories, and didn't put any files. Try checking the docs and see if you got it correctly. It only put the files and created them at the root directory but not in the system directories that you made for COSC.
Quote from: Lupus590 on Jan 20, 2021, 12:00 PMAre you sure that you are getting the raw URL right?
It looks like this
https://gitlab.com/hbomb79/Titanium/-/blob/develop/src/loadFirst.cfg
should turn into this
https://gitlab.com/hbomb79/Titanium/-/raw/develop/src/loadFirst.cfg
I was using the raw api not that but ill try it