0

If it is a duplicate I am sorry, however I've read lots of threads and none of them worked and
only a few of them were related to R.

I want to automate an R script using github actions. So doing that I need to pass some keys, tokens and etc.
However I want to hide them from public while my repo is still public. What I have done so far is:


git add -A(.gitignore does not include .Renviron)
git commit -m 'message'
git push
(Now this works, but my .Renviron still viewable)
git add .gitignore(add .Renviron in .gitignore, while .Renviron is in github repo)
git commit -m 'message'
git push
(Now this works, but .Renviron is still visible publicly)
Then
git rm .Renviron
git commit -m 'message'
git push
(This time as you can imagine required environment objects cant be found.)

Any help appreciated. I feel somehow near to the solution but I do something wrong or
miss something

badalovi
  • 124
  • 8
  • 1
    Take a look at https://docs.github.com/en/rest/reference/actions#secrets – mhovd Jul 19 '21 at 10:18
  • Thank you for sharing. I took a look, but still do not understand as I am not developer. Because what they document seems to me in a bit difficult language. – badalovi Jul 19 '21 at 17:13
  • Don't worry, I can write up an answer later today. – mhovd Jul 19 '21 at 17:15
  • Would appreciate. However what you shared is something githubs's secret rather than hiding your project language env file in .gitignore. However , I look forward to. – badalovi Jul 19 '21 at 17:17

0 Answers0