# MkLink软链接 **Repository Path**: devret/mklink ## Basic Information - **Project Name**: MkLink软链接 - **Description**: MkLink是一款基于JavaFX开发的Windows系统盘空间清理工具,通过创建目录软链接(Ntfs软链接)将占用空间大的文件夹迁移到其他磁盘,从而释放宝贵的系统盘空间。 - **Primary Language**: Java - **License**: AGPL-3.0 - **Default Branch**: master - **Homepage**: https://gitee.com/devret/mklink - **GVP Project**: No ## Statistics - **Stars**: 21 - **Forks**: 4 - **Created**: 2023-08-20 - **Last Updated**: 2026-01-29 ## Categories & Tags **Categories**: Uncategorized **Tags**: None ## README # MkLink - Symbolic Link Tool [中文版本](README.md) ## Introduction MkLink is a Windows disk space management tool developed with JavaFX that creates directory symbolic links (NTFS soft links) to move large folders to other disks, thereby freeing up valuable system disk space. ### Background Many applications generate configuration files and cache data on the system disk (C drive), especially in the following directories: - C:\Users\Username\AppData\Local\xxx - C:\Users\Username\AppData\Roaming\xxx Over time, these folders can occupy a large amount of system disk space. The MkLink tool migrates these folders to other disks by creating symbolic links while keeping applications running normally. ### Features 1. Graphical user interface, easy to use 2. Automatically migrate folders and folders 3. Creates NTFS symbolic links, transparent to applications 4. Multi-threaded processing for improved performance with large folders 5. Multi-language support (Chinese/English interface) 6. Real-time log output for monitoring operations ## Software Architecture and Principles ### Technology Stack - **Programming Language**: Java 11 - **UI Framework**: JavaFX - **Build Tool**: Maven - **Utility Library**: Hutool - **Packaging**: [exe4j](https://exe4j.apponic.com/) + [Inno Setup](https://jrsoftware.org/isdl.php) ### Working Principle When migrating a source directory to a target location, the tool executes the following steps: 1. Scan all files and subdirectories under the source directory 2. Move files and subdirectories directly to the target location (using Java NIO Files.move method) 3. Delete the source directory (ensure related software is closed to avoid file locks) 4. Create an NTFS symbolic link from the source to the target directory The entire moving process uses multi-threaded processing, which can significantly improve the processing speed of large folders. The number of threads can be adjusted in the interface, with a default of 2 times the number of CPU cores. ## Installation Instructions 1. Download and run the installer 2. The software will automatically install the Java runtime environment and application 3. Start the software (recommended to run as administrator) ## User Guide ### Basic Operations 1. **Create Symbolic Link**: - Select source path (folder to migrate) - Select target path (migration destination, will be created automatically if not exists) - Click "Create Symlink" button 2. **Remove Symbolic Link**: - Select source path (folder with existing symbolic link) - Click "Remove Symlink" button ### Important Notes - Run this tool as administrator - Close related software before operation to ensure files are not locked - This involves file deletion operations, please backup important data in advance - Thread count can be adjusted, default is 2 times the number of CPU cores ## Interface Preview ![Software Interface](./src/main/resources/images/mklink_en.png) ## Development Guide ### Requirements - JDK 11 or higher - Maven 3.6+ ### Build Project ```bash mvn clean package ``` ### Run Project ```bash mvn javafx:run ``` ## Contributing 1. Fork the repository 2. Create your feature branch (git checkout -b feature/AmazingFeature) 3. Commit your changes (git commit -m 'Add some AmazingFeature') 4. Push to the branch (git push origin feature/AmazingFeature) 5. Open a pull request