Skip to content
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

Can't create a symlink with target path behaving like a root directory #6

Closed
Ryder17z opened this issue Apr 5, 2023 · 5 comments
Closed
Labels
good first issue Good for newcomers

Comments

@Ryder17z
Copy link

Ryder17z commented Apr 5, 2023

So. I have the paths;
/documents/assets/3d models/
/documents/projects/game/assets/models/

When creating a symlink with this tool, the path I get is unable as it will be the equivalent of:
/documents/projects/game/assets/models/3d models/*.*

But I need the path to be the equivalent of:
/documents/projects/game/assets/models/*.*

I hope this makes sense as it would save me a ton of storage space not having to just copy the files over.

@arnobpl
Copy link
Owner

arnobpl commented May 24, 2023

What I understand is that:
You want the files in /documents/assets/3d models/ directory to be symlinked inside /documents/projects/game/assets/models/ directory. For example, you have these files:

  • /documents/assets/3d models/my_model1.fbx
  • /documents/assets/3d models/my_model2.fbx
  • /documents/assets/3d models/my_model3.fbx

You want them to be symlinked so that you can access these files by these paths respectively:

  • /documents/projects/game/assets/models/my_model1.fbx
  • /documents/projects/game/assets/models/my_model2.fbx
  • /documents/projects/game/assets/models/my_model3.fbx
    Please let me know if that is not what you wanted.

If the above-mentioned is what you want, you can do that using the existing version. What you need to do is:

  • Drag-n-drop all the files/folders (can use "Ctrl + A" shortcut) from File Explorer to SymlinkCreator's Source file or folder list.
  • Use /documents/projects/game/assets/models/ as your Destination path.
  • Click Create symlinks button.
    You are done.

Happy symlinking! :)

@arnobpl arnobpl closed this as completed May 24, 2023
@arnobpl arnobpl added the good first issue Good for newcomers label May 24, 2023
@Ryder17z
Copy link
Author

Ryder17z commented May 24, 2023 via email

@arnobpl
Copy link
Owner

arnobpl commented May 24, 2023

I understand what you saying. When you create/delete/rename files in the source directory, the symlinked files will not be synced in the destination directory. But this is how symlink works internally at the file-system level. Every file need to be symlinked. If you want files in two directories synced by symlinks, then a background app will be required that will check for changes and make the two directories synced. There is no other alternative to make them synced since symlinks are static.

I believe you can still resolve the issue without using any app that is needed to be run in the background. It depends on the 3D modeling software you are using. If I were you, I might want to look for a way to change the project path in the 3D modeling software with the symlinked directory.

Hope that helps. Feel free if you have any related questions.

@Ryder17z
Copy link
Author

Ryder17z commented May 24, 2023 via email

@arnobpl
Copy link
Owner

arnobpl commented May 24, 2023

The file system has not been changed that much. Windows XP had NTFS file system support. Windows 11 has the same file system. It has not changed that much. We still see limitations like the default file path size cap (which can be updated though) if a file is highly nested in a directory. The improvement has been more focused on the security and reliability of storing files rather than adding more features at the file-system level.

Anyway, there is still another way I think of if your example /documents/projects/game/assets/models/ directory only contains the symlinked files/folders from /documents/assets/3d models/ and no additional files/folders. To do so:

  • Drag-n-drop /documents/assets/3d models/ directory to SymlinkCreator's Source file or folder list.
  • Use /documents/projects/game/assets/ as your Destination path.
  • Click Create symlinks button.
  • So you will have a symlinked directory: documents/projects/game/assets/3d models/
  • Delete this directory: /documents/projects/game/assets/models/ since you do not have additional files/folders (this is a condition for this solution).
  • Rename the symlinked directory from /documents/projects/game/assets/3d models/ to /documents/projects/game/assets/models/
    You are done.

Happy symlinking! :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
good first issue Good for newcomers
Projects
None yet
Development

No branches or pull requests

2 participants