[ 
https://issues.apache.org/jira/browse/CB-11730?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15430255#comment-15430255
 ] 

ASF GitHub Bot commented on CB-11730:
-------------------------------------

GitHub user ahirun0426 opened a pull request:

    https://github.com/apache/cordova-lib/pull/484

    [CB-11730] Modify condition of if clause to avoid similar project nam…

    …e with plugin name
    
    The original if clause accepts 
     c:\work\SimplePlugin_TestBed with c:\work\SimplePlugin
    
    So I add \ to the plugin directory name for only enable the if clause to 
complete match the directory name.
     c:\work\SimplePlugin\
    
    nodejs.org description explains the path.resolve removes trailing slashes, 
the code should work with the situation.
    
    
https://nodejs.org/dist/latest-v6.x/docs/api/path.html#path_path_resolve_path
    'The resulting path is normalized and trailing slashes are removed unless 
the path is resolved to the root directory.'

You can merge this pull request into a Git repository by running:

    $ git pull https://github.com/ahirun0426/cordova-lib master

Alternatively you can review and apply these changes as the patch at:

    https://github.com/apache/cordova-lib/pull/484.patch

To close this pull request, make a commit to your master/trunk branch
with (at least) the following in the commit message:

    This closes #484
    
----
commit ea2759a477045238b34fcacee14fcc0e1aea6162
Author: yseki <[email protected]>
Date:   2016-08-22T07:40:31Z

    [CB-11730] Modify condition of if clause to avoid similar project name with 
plugin name

----


> plugman miss the last file/folder when installing plugin on windows
> -------------------------------------------------------------------
>
>                 Key: CB-11730
>                 URL: https://issues.apache.org/jira/browse/CB-11730
>             Project: Apache Cordova
>          Issue Type: Bug
>          Components: Plugman
>    Affects Versions: 6.0.0
>         Environment: Windows
> plugman --version
> 1.2.1
> cordova --version
> 6.3.1
>            Reporter: Yasuharu Seki
>            Priority: Trivial
>
> Steps to reproduce:
> - Create simple plugin
> $ plugman create --name SimplePlugin --plugin_id org.simple.plugin 
> --plugin_version 1.0.0
> - Create cordova project it includes the name of plugin
> $ cordova create SimplePlugin_TestBed
> - Install the plugin into the created project
> $ cordova plugin add ../SimplePlugin
> -> Check the plugins/org.simple.plugin folder
>   Find www/ folder is missing.
> The reason is filenames.indexOf(relativeRootFolder) returns -1 when the 
> target folder name cannot find in the plugin folder.
> The original code works good when the project is on the child folder.
> [plugin]/[project of plugin_testbed]
> But does not the project as sibling.
> [plugin]
> [project of plugin_testbed]



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to