Code Monkey home page Code Monkey logo

Comments (7)

fcyron avatar fcyron commented on August 13, 2024 1

The rest of the changes works as expected. I close this ticket.
Thank you for your quick response!

from rsync4j.

fracpete avatar fracpete commented on August 13, 2024

With commit 51f41ba, the following example code:

public class PathTest {
  public static void main(String[] args) throws Exception {
    String p;
    p = "rsync://localhost:21234/someDir/";
    System.out.println(p + "\n  " + Binaries.convertPath(p));
    p = "c:\\tmp\\myfile.txt";
    System.out.println(p + "\n  " + Binaries.convertPath(p));
    p = "\\\\host\\share\\myfile.txt";
    System.out.println(p + "\n  " + Binaries.convertPath(p));
    p = "/home/some/where/myfile.txt";
    System.out.println(p + "\n  " + Binaries.convertPath(p));
  }
}

Now outputs this (under Windows only!):

rsync://localhost:21234/someDir/
  rsync://localhost:21234/someDir/
c:\tmp\myfile.txt
  /cygdrive/c/tmp/myfile.txt
\\host\share\myfile.txt
  \\host\share\myfile.txt
/home/some/where/myfile.txt
  /home/some/where/myfile.txt

Will push out a bugfix release shortly.

from rsync4j.

fracpete avatar fracpete commented on August 13, 2024

Release 3.2.7-4 is now available:
https://github.com/fracpete/rsync4j/releases/tag/rsync4j-pom-3.2.7-4

May still take a few hours before artifacts have been sync'ed with Maven Central.

Please give it a go and let me know how you get on. If the problem is solved, then please close this issue. Otherwise, please report back.

from rsync4j.

fcyron avatar fcyron commented on August 13, 2024

Sorry, I closed this too eary.

from rsync4j.

fcyron avatar fcyron commented on August 13, 2024

Just a quick question: I guess, we still need to set special permissions when we use rsync under windows? Or is this handled by your library?

from rsync4j.

fracpete avatar fracpete commented on August 13, 2024

Please clarify what you mean by special permissions.

from rsync4j.

fcyron avatar fcyron commented on August 13, 2024

When I transfer a file with rsync from Unix to Windows, I have to add the command line arguments
"--perms --chmod=a=rwx,Da+x". Otherwise I cannot access the file on the windows filesystem. This has nothing to do with your library per se, I just thought that it would be nice to be able to use your library on both windows and unix systems without having to change my code.

-> I do not know if this can be done in your library as I don't fully understand why this --perms and --chmod is necessary on the windows OS. I just got the solution from stackoverflow and it works. (https://stackoverflow.com/questions/5798807/rsync-on-windows-wrong-permissions-for-created-directories)

from rsync4j.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.