PengJingzhao opened a new issue, #5976:
URL: https://github.com/apache/shenyu/issues/5976
### Is there an existing issue for this?
- [x] I have searched the existing issues
### Current Behavior
[BUG] Unable to clone and checkout the ShenYu repository due to "Filename
too long" error during the process.
From the error messages, the issue appears to be related to file path length
exceeding the maximum allowed by the operating system during the clone and
checkout process. However, the repository was cloned to the root of the D
drive, which should have minimized the path length.
To resolve the issue, I suggest the following potential solutions:
1. Enable support for long file paths in Windows:
- Open `Group Policy Editor` and navigate to `Computer Configuration ->
Administrative Templates -> System -> Filesystem`.
- Enable the policy named `Enable Win32 long paths`.
2. Update Git configuration to support long paths:
- Run the command: `git config --system core.longpaths true`.
3. Clone the repository using a shorter directory path or try moving the
repository to another location. For example, clone to `C:\shenyu`.
If the issue persists, please provide additional guidance.
### Expected Behavior
Successfully clone the ShenYu repository and checkout the working tree
without any errors.
### Steps To Reproduce
1. Fork the ShenYu repository to your GitHub account.
2. Clone the repository to your local machine using the following command:
```bash
git clone https://github.com/<your-username>/shenyu.git
```
3. Observe the error during the clone process:
```vb
Cloning into 'D:\shenyu'...
remote: Enumerating objects: 157976, done.
remote: Counting objects: 100% (6791/6791), done.
remote: Compressing objects: 100% (481/481), done.
remote: Total 157976 (delta 6537), reused 6317 (delta 6300), pack-reused
151185
Receiving objects: 100% (157976/157976), 61.53 MiB | 1.86 MiB/s, done.
Resolving deltas: 100% (54177/54177), done.
error: unable to create file
shenyu-spring-boot-starter/shenyu-spring-boot-starter-plugin/shenyu-spring-boot-starter-plugin-dubbo/shenyu-spring-boot-starter-plugin-apache-dubbo/src/main/java/org/apache/shenyu/springboot/starter/plugin/apache/dubbo/ApacheDubboPluginConfiguration.java:
Filename too long
error: unable to create file
shenyu-spring-boot-starter/shenyu-spring-boot-starter-plugin/shenyu-spring-boot-starter-plugin-dubbo/shenyu-spring-boot-starter-plugin-apache-dubbo/src/test/java/org/apache/shenyu/springboot/starter/plugin/apache/dubbo/ApacheDubboPluginConfigurationTest.java:
Filename too long
Updating files: 100% (4230/4230), done.
fatal: unable to checkout working tree
warning: Clone succeeded, but checkout failed. You can inspect what was
checked out with 'git status' and retry with 'git restore --source=HEAD :/'
```
### Environment
```markdown
ShenYu version(s): master
Operating System: Windows
Git version: 2.x
Disk location for clone: D:\ (Root directory)
```
### Debug logs
_No response_
### Anything else?
_No response_
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]