Skip to content

Commit

Permalink
refactor: remove 'workspace' and 'members' in favor of 'workspaces'
Browse files Browse the repository at this point in the history
  • Loading branch information
bartlomieju committed Nov 15, 2023
1 parent afe07ac commit bf55b10
Showing 1 changed file with 3 additions and 5 deletions.
8 changes: 3 additions & 5 deletions src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -477,11 +477,9 @@ pub struct ConfigFileJson {
pub name: Option<String>,
pub version: Option<String>,
#[serde(default)]
pub workspace: bool,
pub workspaces: Vec<String>,
pub exports: Option<Value>,
#[serde(default)]
pub members: Vec<String>,
#[serde(default)]
pub unstable: Vec<String>,
}

Expand Down Expand Up @@ -866,9 +864,9 @@ impl ConfigFile {
};

let config_file_directory = config_file_path.parent().unwrap();
let mut members = Vec::with_capacity(self.json.members.len());
let mut members = Vec::with_capacity(self.json.workspaces.len());

for member in self.json.members.iter() {
for member in self.json.workspaces.iter() {
let member_path = config_file_directory.join(member);
let member_deno_json = member_path.as_path().join("deno.json");
if !member_deno_json.exists() {
Expand Down

0 comments on commit bf55b10

Please sign in to comment.