You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@weex.apache.org by GitBox <gi...@apache.org> on 2019/07/15 10:25:39 UTC

[GitHub] [incubator-weex-playground] wrmswindmill removed a comment on issue #6: configure weex_sdk source.

wrmswindmill removed a comment on issue #6:  configure weex_sdk source.
URL: https://github.com/apache/incubator-weex-playground/pull/6#issuecomment-511271130
 
 
   I have tried to use `if else` in Podfile with the below codes:
   ```ruby
   def common
        # check if weex-playground is a submodule
        if File.file?('../../.gitmodules')
            pod 'WeexSDK', :path => '../../'
        else
            pod 'WeexSDK', :git => 'https://github.com/apache/incubator-weex.git'
   ```
   but when I run `pod install`,then I receive the below error message:
    ```
    [!] Invalid `Podfile` file: syntax error, unexpected end-of-input, expecting keyword_end
   ````
   
   I change the code to:
   ```ruby
   def common
       pod 'WeexSDK', :path => '../../' if File.file?('../../.gitmodules')
       pod 'WeexSDK', :git => 'https://github.com/apache/incubator-weex.git' if !File.file?('../../.gitmodules')
   ```
   EveryThing work well.
   
   BTW: Podfile is Ruby-based.

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
users@infra.apache.org


With regards,
Apache Git Services