Skip to content

Commit

Permalink
feat: move FileCollector to deno_config (#70)
Browse files Browse the repository at this point in the history
Moved from the CLI.

CLI PR: denoland/deno#24433
  • Loading branch information
dsherret committed Jul 5, 2024
1 parent 3fbd090 commit aef527e
Show file tree
Hide file tree
Showing 8 changed files with 858 additions and 16 deletions.
119 changes: 119 additions & 0 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

3 changes: 2 additions & 1 deletion Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 9,7 @@ repository = "https://github.com/denoland/deno_config"

[features]
default = ["workspace"]
deno_json = ["jsonc-parser", "glob", "import_map"]
deno_json = ["jsonc-parser", "glob", "ignore", "import_map"]
package_json = ["deno_semver"]
sync = []
workspace = ["deno_json", "package_json"]
Expand All @@ -20,6 20,7 @@ indexmap = { version = "2", features = ["serde"] }
jsonc-parser = { version = "0.23.0", features = ["serde"], optional = true }
log = "0.4.20"
glob = { version = "0.3.1", optional = true }
ignore = { version = "0.4", optional = true }
percent-encoding = "2.3.0"
serde = { version = "1.0.149", features = ["derive"] }
serde_json = "1.0.85"
Expand Down
2 changes: 1 addition & 1 deletion src/deno_json/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -727,7 727,7 @@ impl ConfigFile {
config_path: &Path,
parse_options: &ConfigParseOptions,
) -> Result<Self, ConfigFileReadError> {
let text = fs.read_to_string(config_path).map_err(|err| {
let text = fs.read_to_string_lossy(config_path).map_err(|err| {
ConfigFileReadError::FailedReading {
specifier: specifier.clone(),
source: err,
Expand Down
Loading

0 comments on commit aef527e

Please sign in to comment.