Hacktoberfest 2026:维护者为十月标记出来的 issue,仍然开放、适合新手。 浏览 Hacktoberfest issue

Add `Path.absolute` or `Path.canonical`

未关闭
#162 3 条评论 0 个 reaction 已指派 0 人 在 GitHub 查看

维护者通常 1 天内回复

还没有人认领这个 Issue。

评估

难度
4/5
预计耗时
3-5 天
新手友好度
45/100
Issue 类型
功能
描述清晰度
基本清楚
活跃度
冷清
技术栈
rust
领域
cli

调研方向

从 Path 模块开始,检查其现有的路径操作和平台入口点。明确新的 API 应提供绝对行为还是规范行为,然后验证相对输入和绝对输入都会产生约定的绝对路径结果。

由索引模型根据 Issue 内容生成。

描述

enhancement good first issue

Hi, long time listener, first time problem-maker 😅. I am trying to build a simple CLI in roc and when I found the Path module I was hoping to convert a relative path to an absolute one but failed to find the functionality to do so? Did I miss it? Could it be added? (Would offer to try myself but I am painfully aware of my current skill level ☺️).

My expectation would be that it takes a string representing either a relative or absolute path and returns the absolute path. Java, I think distinguishes between "absolute" and "canonical" paths. To my understanding, the difference is the latter resolves syntax like ".." while the former would just include the ".." in the path. FWIW I personally prefer the latter's behaviour and the former's name.

主要语言
Rust
星标
121
派生
46
平均合并
21 小时 2 分钟
30 天内合并 PR
13

环境准备

  • 没有 Dockerfile 或 Docker Compose 文件
  • 没有 Pull Request 模板
  • 阅读贡献指南

从这里开始

  1. 先读完整个 Issue,再读项目的贡献指南。
  2. 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
  3. Fork 仓库,在一个分支上完成修改。
  4. 提交 Pull Request,并在描述里引用这个 Issue 编号。

roc-lang/basic-cli 的其他 Issue

查看 roc-lang/basic-cli 的全部 Issue

相似的 Issue

更多 Rust Issue

把新 issue 发到你的邮箱

精选适合新手参与的 GitHub issue 摘要。