apache / apache/maven-assembly-plugin
[MASSEMBLY-776] File's source does not take some cases of absolute paths as absolute paths.
- Dominant language
- Java
- Stars
- 110
- Forks
- 75
- Avg merge
- 12h 54m
- Merged PRs (30d)
- 10
Description
**[Vinicius Dantas](https://issues.apache.org/jira/secure/ViewProfile.jspa?name=vmelo)** opened **[MASSEMBLY-776](https://issues.apache.org/jira/browse/MASSEMBLY-776?redirect=false)** and commented
Using an absolute path that starts with either forward or backward slash is not accepted.
It happens because Java's File.isAbsolute() does not recognize paths starting at either forward or backward as absolute paths on Windows. However, those prefixes are acceptable on Windows.
This function is used at main/java/org/apache/maven/plugin/assembly/archive/phase/FileItemAssemblyPhase.java, line 76 to know if the source is either absolute or relative.
---
**Affects:** 2.5.5
Contributor guide
No contributing guide indexed for this repository
Research direction
Start at main/java/org/apache/maven/plugin/assembly/archive/phase/FileItemAssemblyPhase.java, around line 76, where File.isAbsolute() determines whether the source is absolute or relative. Reproduce the Windows cases described for paths beginning with a forward or backward slash, then verify that those sources are treated as absolute without changing normal relative-path handling.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- java
- Domain
- build-system
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Clearly specified
- Newbie friendliness
- 48/100