Skip to content

missing support for symlinks for windows #6893

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

Open
tenbaht opened this issue Nov 6, 2017 · 0 comments
Open

missing support for symlinks for windows #6893

tenbaht opened this issue Nov 6, 2017 · 0 comments
Labels
Component: IDE The Arduino IDE feature request A request to make an enhancement (not a bug fix) IDE 1.9.x Beta Related to the Arduino IDE Beta Build
Milestone

Comments

@tenbaht
Copy link

tenbaht commented Nov 6, 2017

unpacking a platform package fails for windows if the archive file contains a symlink.

This is because Platform.java defines the (Unix) command ln -s for this purpose and windows/Platform.java does not overload this with an equivalent definition for windows.

An example of the full error message can be found in issue report #25 on Sduino project where I use symlinks in a platform package.

Symlinks are supported since Windows Vista by the command mklink. I suggest a modification for src/processing/app/windows/Platform.java like this (untested, since I don't have all this java stuff set up here):

--- src/processing/app/windows/Platform.java	2017-10-30 11:04:26.000000000 +0100
+++ src/processing/app/windows/Platform.java.new	2017-11-06 12:16:13.167549867 +0100
@@ -212,7 +212,10 @@
     return scripts;
   }
 
+  @Override
   public void symlink(File something, File somewhere) throws IOException, InterruptedException {
+    Process process = Runtime.getRuntime().exec(new String[]{"mklink", somewhere.getAbsolutePath(), something}, null, somewhere.getParentFile());
+    process.waitFor();
   }
 
   @Override

A similar modification might be useful for hardlinks as well.

@facchinm facchinm added Component: IDE The Arduino IDE feature request A request to make an enhancement (not a bug fix) labels Nov 6, 2017
@facchinm facchinm added this to the Next milestone Nov 10, 2017
facchinm added a commit that referenced this issue Dec 7, 2017
@facchinm facchinm added the IDE 1.9.x Beta Related to the Arduino IDE Beta Build label Dec 11, 2017
facchinm added a commit that referenced this issue Dec 13, 2017
facchinm added a commit that referenced this issue Jan 11, 2018
facchinm added a commit to facchinm/Arduino that referenced this issue Jan 22, 2018
facchinm added a commit that referenced this issue Feb 16, 2018
facchinm added a commit that referenced this issue Apr 12, 2018
facchinm added a commit that referenced this issue Apr 17, 2018
facchinm added a commit to facchinm/Arduino that referenced this issue May 8, 2018
cmaglie pushed a commit to facchinm/Arduino that referenced this issue May 8, 2018
cmaglie pushed a commit to facchinm/Arduino that referenced this issue May 9, 2018
facchinm added a commit that referenced this issue May 14, 2018
facchinm added a commit that referenced this issue May 14, 2018
facchinm added a commit that referenced this issue May 15, 2018
cmaglie pushed a commit that referenced this issue May 17, 2018
facchinm added a commit that referenced this issue May 22, 2018
facchinm added a commit that referenced this issue May 30, 2018
facchinm added a commit that referenced this issue Jun 12, 2018
facchinm added a commit that referenced this issue Jul 19, 2018
facchinm added a commit that referenced this issue Aug 20, 2018
facchinm added a commit that referenced this issue Aug 23, 2018
facchinm added a commit that referenced this issue Sep 10, 2018
facchinm added a commit that referenced this issue Oct 5, 2018
facchinm added a commit that referenced this issue Oct 16, 2018
facchinm added a commit that referenced this issue Nov 21, 2018
facchinm added a commit that referenced this issue Dec 5, 2018
facchinm added a commit that referenced this issue Dec 13, 2018
facchinm added a commit that referenced this issue Jan 18, 2019
facchinm added a commit that referenced this issue Jan 19, 2019
facchinm added a commit that referenced this issue Jan 21, 2019
facchinm added a commit that referenced this issue Mar 7, 2019
facchinm added a commit that referenced this issue Mar 8, 2019
facchinm added a commit that referenced this issue Mar 18, 2019
facchinm added a commit that referenced this issue May 14, 2019
facchinm added a commit that referenced this issue May 14, 2019
facchinm added a commit that referenced this issue Jul 18, 2019
facchinm added a commit that referenced this issue Jul 18, 2019
facchinm added a commit that referenced this issue Jul 19, 2019
facchinm added a commit that referenced this issue Jul 23, 2019
facchinm added a commit that referenced this issue Sep 20, 2019
facchinm added a commit that referenced this issue Sep 30, 2019
facchinm added a commit that referenced this issue Oct 22, 2019
facchinm added a commit that referenced this issue Feb 13, 2020
facchinm added a commit that referenced this issue Mar 23, 2020
facchinm added a commit that referenced this issue Apr 7, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Component: IDE The Arduino IDE feature request A request to make an enhancement (not a bug fix) IDE 1.9.x Beta Related to the Arduino IDE Beta Build
Projects
None yet
Development

No branches or pull requests

2 participants