Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix issue #243 #244

Open
wants to merge 4 commits into
base: master
Choose a base branch
from
Open

fix issue #243 #244

wants to merge 4 commits into from

Conversation

Orange-W
Copy link
Contributor

fix issue #243
Dictionary missing ';' after key-value pair for "ORGANIZATIONNAME", found "@" (Nanaimo::Reader::ParseError)

fix Dictionary missing ';' after key-value pair for "ORGANIZATIONNAME", found "@" (Nanaimo::Reader::ParseError)
@Orange-W
Copy link
Contributor Author

The Travis CI build failed may be the same as the Xcode image version question.
GabLeRoux/example-pod-using-restkit#4

This comment travis-ci/docs-travis-ci-com#1106 (comment) suggests that using xcode10.3 image will solve the problem 👍

@orta
Copy link
Member

orta commented Sep 23, 2019

I don't think this would fix it - I think you need to manually fix the xcodeproj file to wrap with quotes. You might end up with orgs which have extra quotes in them

@Orange-W
Copy link
Contributor Author

Orange-W commented Sep 25, 2019

I think this problem is purely a matter of code. In the source code logic, if the default organization is not set, the github name will be taken as the organization name.The default is the email address. As a result, the automation script fails to run.

But as a better way, I think I can translate the content,like str.delete('\'\"').

as:

    def replace_variables_in_files
        file_names = ['POD_LICENSE', 'POD_README.md', 'NAME.podspec', '.travis.yml', podfile_path]
        file_names.each do |file_name|
        text = File.read(file_name)
        text.gsub!("${POD_NAME}", @pod_name)
        text.gsub!("${REPO_NAME}", @pod_name.gsub('+', '-'))
        text.gsub!("${USER_NAME}", user_name)
        ...
    end

    def user_name
      (ENV['GIT_COMMITTER_NAME'] || github_user_name || `git config user.name` || `<GITHUB_USERNAME>` ).strip
    end

    def github_user_name
      github_user_name = `security find-internet-password -s github.com | grep acct | sed 's/"acct"<blob>="//g' | sed 's/"//g'`.strip
      is_valid = github_user_name.empty? or github_user_name.include? '@'
      return is_valid ? nil : github_user_name
    end

@orta
Copy link
Member

orta commented Sep 25, 2019

Yeah, removing quotes from inside the string could work with the current PR 👍

@Orange-W
Copy link
Contributor Author

Orange-W commented Dec 2, 2019

Existing issues have been fixed

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants