Encrypting Files Failed

I ensure service-account.json is under current directory, and it create service-account.json.enc for me but sill got error :

  1. docker run -it -v ${pwd}:/app ruby sh
  2. gem install travis
  3. travis login --github-token MY_TOCKEN --com
  4. travis encrypt-file service-account.json -r myname/k8s-gcp --com

travis encrypt-file service-account.json -r myname/k8s-gcp --com

encrypting service-account.json for williamlin0518/k8s-gcp
storing result as service-account.json.enc
storing secure env variables for decryption
wrong number of arguments (given 0, expected 1…3)
for a full error report, run travis report --pro
螢幕擷取畫面 2023-12-02 010709

travis report --pro

Ruby: Ruby 3.2.2-p53
Operating System: Linux
RubyGems: RubyGems 3.4.10

Version: 1.11.1
Plugins: none
Auto-Completion: yes
Last Version Check: 2023-12-01 16:47:54 +0000

API Endpoint: https://api.travis-ci.com/
Logged In: as “myname”
Verify SSL: yes
Enterprise: no

com: https://api.travis-ci.com/ (access token, current)

Last Exception
An error occurred running travis encrypt-file --pro:
ArgumentError: wrong number of arguments (given 0, expected 1…3)
from /usr/local/bundle/gems/json_pure-2.7.0/lib/json/common.rb:614:in dump' from /usr/local/bundle/gems/travis-1.11.1/lib/travis/client/env_var.rb:38:in add’
from /usr/local/bundle/gems/travis-1.11.1/lib/travis/client/env_var.rb:49:in upsert' from /usr/local/bundle/gems/travis-1.11.1/lib/travis/cli/encrypt_file.rb:77:in set_env_vars’
from /usr/local/bundle/gems/travis-1.11.1/lib/travis/cli/encrypt_file.rb:42:in run' from /usr/local/bundle/gems/travis-1.11.1/lib/travis/cli/command.rb:200:in execute’
from /usr/local/bundle/gems/travis-1.11.1/lib/travis/cli.rb:64:in run' from /usr/local/bundle/gems/travis-1.11.1/bin/travis:18:in <top (required)>’
from /usr/local/bundle/bin/travis:25:in load' from /usr/local/bundle/bin/travis:25:in

Hi @williamlin0518,

Could you try specifying -r OWNER/REPO then? (--debug might also give additional information.)