为什么 fastlane 匹配让我输入密码,即使我已经输入了

why the fastlane match make me input the Passphrase even I already input

现在我正在使用此命令在 macOS Big Sur 中使用 fastlane 匹配生成分发证书:

fastlane match adhoc

在我 运行 这个命令之后,它告诉我输入 Passphrase for Match storage:

[✔] 
[15:03:31]: fastlane detected a Gemfile in the current directory
[15:03:31]: However, it seems like you didn't use `bundle exec`
[15:03:31]: To launch fastlane faster, please use
[15:03:31]:
[15:03:31]: $ bundle exec fastlane match adhoc
[15:03:31]:
[15:03:31]: Get started using a Gemfile for fastlane https://docs.fastlane.tools/getting-started/ios/setup/#use-a-gemfile
[15:03:32]: In the config file './fastlane/Matchfile' you have the line git_url, but didn't provide any value. Make sure to append a value right after the option name. Make sure to check the docs for more information
[15:03:32]: In the config file './fastlane/Matchfile' you have the line username, but didn't provide any value. Make sure to append a value right after the option name. Make sure to check the docs for more information
[15:03:32]: Successfully loaded '/Users/dolphin/Documents/GitHub/flutter-netease-music/ios/fastlane/Matchfile' 

+-----------------+---------------------------+
| Detected Values from './fastlane/Matchfile' |
+-----------------+---------------------------+
| git_branch      | master                    |
| storage_mode    | git                       |
| type            | adhoc                     |
| app_identifier  | ["com.reddwarf.musicapp"] |
+-----------------+---------------------------+


+--------------------------------+---------------------------+
|                 Summary for match 2.187.0                  |
+--------------------------------+---------------------------+
| type                           | adhoc                     |
| readonly                       | false                     |
| generate_apple_certs           | true                      |
| skip_provisioning_profiles     | false                     |
| app_identifier                 | ["com.reddwarf.musicapp"] |
| username                       | 343735881@qq.com          |
| team_id                        | 6JP4P88ZJB                |
| storage_mode                   | git                       |
| git_branch                     | master                    |
| shallow_clone                  | false                     |
| clone_branch_directly          | false                     |
| keychain_name                  | login.keychain            |
| force                          | false                     |
| force_for_new_devices          | false                     |
| skip_confirmation              | false                     |
| skip_docs                      | false                     |
| platform                       | ios                       |
| derive_catalyst_app_identifier | false                     |
| fail_on_name_taken             | false                     |
| skip_certificate_matching      | false                     |
| skip_set_partition_list        | false                     |
| verbose                        | false                     |
+--------------------------------+---------------------------+

[15:03:32]: To not be asked about this value, you can specify it using 'git_url'
[15:03:32]: URL to the git repo containing all the certificates: https://github.com/jiangxiaoqiang/music-certificate.git
[15:03:45]: Cloning remote git repo...
[15:03:45]: If cloning the repo takes too long, you can use the `clone_branch_directly` option in match.
[15:03:48]: Checking out branch master...
[15:03:48]: Enter the passphrase that should be used to encrypt/decrypt your certificates
[15:03:48]: This passphrase is specific per repository and will be stored in your local keychain
[15:03:48]: Make sure to remember the password, as you'll need it when you run match on a different machine
[15:03:48]: Passphrase for Match storage: ******
[15:03:55]: Type passphrase again: ******
[15:03:59]: wrong final block length
[15:03:59]: Couldn't decrypt the repo, please make sure you enter the right password!
keychain: "/Users/dolphin/Library/Keychains/jiangxiaoqiang-db"
version: 512
class: "inet"
attributes:
    0x00000007 <blob>="match_https://github.com/jiangxiaoqiang/music-certificate.git"
    0x00000008 <blob>=<NULL>
    "acct"<blob>=<NULL>
    "atyp"<blob>="dflt"
    "cdat"<timedate>=0x32303231303831383037303335395A00  "20210818070359Z[=11=]0"
    "crtr"<uint32>=<NULL>
    "cusi"<sint32>=<NULL>
    "desc"<blob>=<NULL>
    "icmt"<blob>=<NULL>
    "invi"<sint32>=<NULL>
    "mdat"<timedate>=0x32303231303831383037303335395A00  "20210818070359Z[=11=]0"
    "nega"<sint32>=<NULL>
    "path"<blob>=<NULL>
    "port"<uint32>=0x00000000
    "prot"<blob>=<NULL>
    "ptcl"<uint32>=0x00000000
    "scrp"<sint32>=<NULL>
    "sdmn"<blob>=<NULL>
    "srvr"<blob>="match_https://github.com/jiangxiaoqiang/music-certificate.git"
    "type"<uint32>=<NULL>
password has been deleted.
[15:03:59]: Enter the passphrase that should be used to encrypt/decrypt your certificates
[15:03:59]: This passphrase is specific per repository and will be stored in your local keychain
[15:03:59]: Make sure to remember the password, as you'll need it when you run match on a different machine
[15:03:59]: Passphrase for Match storage:

从提示来看,它告诉我为匹配存储设置一个新的密码。然后显示解密失败?如何理解工作流?我在生成开发证书的时候输入了Passphrase,所以无论是新的Passphrase还是我输入的Passphrase都一样的Passphrase,为什么还是提示解密失败?我应该怎么做才能解密成功?

它说,它缺少git_urlusername

[15:03:32]: In the config file './fastlane/Matchfile' you have the line git_url, but didn't provide any value. Make sure to append a value right after the option name. Make sure to check the docs for more information
[15:03:32]: In the config file './fastlane/Matchfile' you have the line username, but didn't provide any value. Make sure to append a value right after the option name. Make sure to check the docs for more information

您是否为 fastlane match 提供了 git repository

我记得我是通过fastlane match appstore生成分发证书的。很难让它发挥作用....


更新:

emmm,好像我以前遇到过同样的问题....在我的笔记本里,留下了下面的评论和我搜索的link

https://github.com/fastlane/fastlane/issues/4020

通过命令fastlane match nuke distribution,可以清除匹配库中的所有内容。然后 fastlane match appstore 可以重新分配一个新的密码。

脚本简介....

## Clean all
fastlane match nuke distribution
## Remake certifications / provisioning profiles, and a new passphrase password
fastlane match appstore

或者,

## No `match nuke distribution`. 
## Renew certifications / provisioning profiles, for TestFlight
fastlane match appstore

如果与 CI 系统(例如:Jenkins)集成,MATCH_PASSWORD 环境变量对我有很大帮助。