You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@cordova.apache.org by ghenry22 <gi...@git.apache.org> on 2015/10/28 06:59:38 UTC

[GitHub] cordova-plugin-file pull request: CB-9887 cordova.file.* paths for...

GitHub user ghenry22 opened a pull request:

    https://github.com/apache/cordova-plugin-file/pull/143

    CB-9887 cordova.file.* paths for windows platform

    Update the plugin to define cordova.file.* paths for windows platform as appropriate.
    
    Documentation updated to show where to store things.
    
    Have tested this in my own app and the paths are detected as file plugin works as expected now.
    
    Means you can use cordova.file.dataDirectory in your app and then run that app on ios, android, windows with consistent behaviour without requiring platform specific code.

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

    $ git pull https://github.com/ghenry22/cordova-plugin-file windows_paths

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

    https://github.com/apache/cordova-plugin-file/pull/143.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 #143
    
----
commit 34a66b89d3e6b9f3c4c43b95adcd60227d2cdc19
Author: ghenry22 <gh...@gmail.com>
Date:   2015-10-28T04:55:14Z

    Add windows paths to cordova.file object
    
    add standard paths to cordova.file object for windows.  Standardises
    behaviour for windows platform and resolves cordova.file is undefined
    errors.

commit 1e4094a2b40f5803f9954bcd3f15664e471c12d4
Author: ghenry22 <gh...@gmail.com>
Date:   2015-10-28T05:01:57Z

    fix

commit d7c0b0beb641a4db51a94235768e0c1873e9f6aa
Author: ghenry22 <gh...@gmail.com>
Date:   2015-10-28T05:37:49Z

    update docs for windows platform details

commit 442973f2646f5767b84dc1e57dc5244afba7db84
Author: ghenry22 <gh...@gmail.com>
Date:   2015-10-28T05:40:34Z

    fix docs formatting

commit 03d9d32a28c0884fe61c16f4f976d9114c316ef7
Author: ghenry22 <gh...@gmail.com>
Date:   2015-10-28T05:42:00Z

    fix docs

----


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@cordova.apache.org
For additional commands, e-mail: dev-help@cordova.apache.org


[GitHub] cordova-plugin-file pull request: CB-9887 cordova.file.* paths for...

Posted by arangas <gi...@git.apache.org>.
Github user arangas commented on the pull request:

    https://github.com/apache/cordova-plugin-file/pull/143#issuecomment-153221198
  
    I see, I wasn't aware of that! I've tested this and looks good, cheers. It would be great to get this merged.


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@cordova.apache.org
For additional commands, e-mail: dev-help@cordova.apache.org


[GitHub] cordova-plugin-file pull request: CB-9887 cordova.file.* paths for...

Posted by purplecabbage <gi...@git.apache.org>.
Github user purplecabbage commented on the pull request:

    https://github.com/apache/cordova-plugin-file/pull/143#issuecomment-153929493
  
    Done! Thanks ghenry22 !


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@cordova.apache.org
For additional commands, e-mail: dev-help@cordova.apache.org


[GitHub] cordova-plugin-file pull request: CB-9887 cordova.file.* paths for...

Posted by ghenry22 <gi...@git.apache.org>.
Github user ghenry22 commented on the pull request:

    https://github.com/apache/cordova-plugin-file/pull/143#issuecomment-153922252
  
    CB-9090 is for the whitelist plugin
    CB-8257 is the same issue but for the wp8 platform.  This fix is for the windows platform, I don't have native code skills to update the wp8 plugin.


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@cordova.apache.org
For additional commands, e-mail: dev-help@cordova.apache.org


[GitHub] cordova-plugin-file pull request: CB-9887 cordova.file.* paths for...

Posted by ghenry22 <gi...@git.apache.org>.
Github user ghenry22 commented on the pull request:

    https://github.com/apache/cordova-plugin-file/pull/143#issuecomment-153925057
  
    MS docs confirm the same, should be ms-appx:///
    
    Committing an update to fix now.
    
    reference:
    https://msdn.microsoft.com/en-us/library/windows.applicationmodel.package.installedlocation.aspx


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@cordova.apache.org
For additional commands, e-mail: dev-help@cordova.apache.org


[GitHub] cordova-plugin-file pull request: CB-9887 cordova.file.* paths for...

Posted by ghenry22 <gi...@git.apache.org>.
Github user ghenry22 commented on the pull request:

    https://github.com/apache/cordova-plugin-file/pull/143#issuecomment-153923917
  
    CB-9020 does say they are targeting WP 8.1 which uses the new windows platform so this PR would also resolve CB-9020.
    
    CB8257 seems to refer specifically to the wp8 platform which uses different native code. Although I thought that wp8 support was deprecated so perhaps that could be closed with a will not fix deprecated and advice to update to target WP8.1 to resolve the issue?
    
    Regarding the path changes you mentioned you're probably right, or maybe it should be ms-appx-web?  I'll do a bit of reading and update the PR if necessary.


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@cordova.apache.org
For additional commands, e-mail: dev-help@cordova.apache.org


[GitHub] cordova-plugin-file pull request: CB-9887 cordova.file.* paths for...

Posted by arangas <gi...@git.apache.org>.
Github user arangas commented on the pull request:

    https://github.com/apache/cordova-plugin-file/pull/143#issuecomment-152005214
  
    I've tested and examined this and it looks great, thanks! Is there any reason not to define applicationStorageDirectory and set it to the same value as dataDirectory?


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@cordova.apache.org
For additional commands, e-mail: dev-help@cordova.apache.org


[GitHub] cordova-plugin-file pull request: CB-9887 cordova.file.* paths for...

Posted by purplecabbage <gi...@git.apache.org>.
Github user purplecabbage commented on the pull request:

    https://github.com/apache/cordova-plugin-file/pull/143#issuecomment-153511867
  
    Hi @ghenry22 !
    This looks good, as do your other prs.  Have you signed an iCLA? [1] 
    It is hard to tell because you do not have your name on your github profile, so I have nothing the verify against [2] 
    
    [1] http://cordova.apache.org/contribute/
    [2]  https://people.apache.org/committer-index.html



---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@cordova.apache.org
For additional commands, e-mail: dev-help@cordova.apache.org


[GitHub] cordova-plugin-file pull request: CB-9887 cordova.file.* paths for...

Posted by asfgit <gi...@git.apache.org>.
Github user asfgit closed the pull request at:

    https://github.com/apache/cordova-plugin-file/pull/143


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@cordova.apache.org
For additional commands, e-mail: dev-help@cordova.apache.org


[GitHub] cordova-plugin-file pull request: CB-9887 cordova.file.* paths for...

Posted by jasongin <gi...@git.apache.org>.
Github user jasongin commented on a diff in the pull request:

    https://github.com/apache/cordova-plugin-file/pull/143#discussion_r43965498
  
    --- Diff: src/windows/FileProxy.js ---
    @@ -168,6 +168,15 @@ WinFS.prototype.__format__ = function(fullPath) {
         return 'cdvfile://localhost' + path;
     };
     
    +var windowsPaths = {
    +    dataDirectory: "ms-appdata:///local/",
    +    cacheDirectory: "ms-appdata:///temp/",
    +    tempDirectory: "ms-appdata:///temp/",
    +    syncedDataDirectory: "ms-appdata:///roaming/",
    +    applicationDirectory: "ms-appdata:///",
    --- End diff --
    
    I think applicationDirectory and applicationStorageDirectory should point to ms-appx:/// rather than ms-appdata:///


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@cordova.apache.org
For additional commands, e-mail: dev-help@cordova.apache.org


[GitHub] cordova-plugin-file pull request: CB-9887 cordova.file.* paths for...

Posted by ghenry22 <gi...@git.apache.org>.
Github user ghenry22 commented on the pull request:

    https://github.com/apache/cordova-plugin-file/pull/143#issuecomment-153536161
  
    @purplecabbage yep I have signed an ICLA and have already had a PR merged into the file plugin.
    
    I'll send you a direct message on slack with full name etc to make it easier to verify


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@cordova.apache.org
For additional commands, e-mail: dev-help@cordova.apache.org


[GitHub] cordova-plugin-file pull request: CB-9887 cordova.file.* paths for...

Posted by jasongin <gi...@git.apache.org>.
Github user jasongin commented on the pull request:

    https://github.com/apache/cordova-plugin-file/pull/143#issuecomment-153923115
  
    Sorry I mistyped... I meant to refer to CB-9020 not CB-9090.
    I was thinking CB-8257 was referring to WP 8.1 (which uses the 'windows' platform for plugins), but it might actually be just WP 8.0, which doesn't support the cordova.file.* paths either.


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@cordova.apache.org
For additional commands, e-mail: dev-help@cordova.apache.org


[GitHub] cordova-plugin-file pull request: CB-9887 cordova.file.* paths for...

Posted by ghenry22 <gi...@git.apache.org>.
Github user ghenry22 commented on the pull request:

    https://github.com/apache/cordova-plugin-file/pull/143#issuecomment-153219294
  
    my understanding is that applicationStorageDirectory is a bit redundant.  It is the same as the applicationDirectory but has a note that you can change to the specific subdirectories that might have write access (ie /local is the same as where dataDirectory already points).
    
    I can add it in case it's useful to someone purely for compatibility though.


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@cordova.apache.org
For additional commands, e-mail: dev-help@cordova.apache.org


[GitHub] cordova-plugin-file pull request: CB-9887 cordova.file.* paths for...

Posted by jasongin <gi...@git.apache.org>.
Github user jasongin commented on the pull request:

    https://github.com/apache/cordova-plugin-file/pull/143#issuecomment-153920849
  
    It looks like CB-9090 and CB-8257 are about exactly the same problem as this CB-9887.


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@cordova.apache.org
For additional commands, e-mail: dev-help@cordova.apache.org


[GitHub] cordova-plugin-file pull request: CB-9887 cordova.file.* paths for...

Posted by ghenry22 <gi...@git.apache.org>.
Github user ghenry22 commented on the pull request:

    https://github.com/apache/cordova-plugin-file/pull/143#issuecomment-153926046
  
    once merged you could also close out PR #121 as duplicate as it attempts to solve the same issue but generates absolute paths from c:\... which are not usable in the app and result in encoding errors when used with file or file transfer plugin.


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@cordova.apache.org
For additional commands, e-mail: dev-help@cordova.apache.org


[GitHub] cordova-plugin-file pull request: CB-9887 cordova.file.* paths for...

Posted by ghenry22 <gi...@git.apache.org>.
Github user ghenry22 commented on the pull request:

    https://github.com/apache/cordova-plugin-file/pull/143#issuecomment-153219744
  
    added applicationStorageDirectory to defined paths and updated readme with relevant comments for this path.


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@cordova.apache.org
For additional commands, e-mail: dev-help@cordova.apache.org