mirror of
https://github.com/nushell/nushell.git
synced 2025-08-19 00:46:01 +02:00
Extract out xpath to a plugin. (#2661)
This commit is contained in:
committed by
GitHub
parent
2573441e28
commit
4e931fa73f
@@ -7,7 +7,8 @@ fn plugins_are_declared_with_wix() {
|
||||
let actual = nu!(
|
||||
cwd: ".", pipeline(
|
||||
r#"
|
||||
echo $(open wix/main.wxs --raw | from xml
|
||||
open Cargo.toml | get bin.name | drop | sort-by | wrap cargo | merge {
|
||||
open wix/main.wxs --raw | from xml
|
||||
| get Wix.children.Product.children.0.Directory.children.0
|
||||
| where Directory.attributes.Id == "$(var.PlatformProgramFilesFolder)"
|
||||
| get Directory.children.Directory.children.0 | last
|
||||
@@ -18,13 +19,9 @@ fn plugins_are_declared_with_wix() {
|
||||
| str substring [_, -4] File.attributes.Name
|
||||
| get File.attributes.Name
|
||||
| sort-by
|
||||
| wrap wix) | merge {
|
||||
open Cargo.toml |
|
||||
get bin.name |
|
||||
drop |
|
||||
sort-by |
|
||||
wrap cargo
|
||||
}
|
||||
| wrap wix
|
||||
}
|
||||
| default wix _
|
||||
| if $it.wix != $it.cargo { = 1 } { = 0 }
|
||||
| math sum
|
||||
"#
|
||||
|
Reference in New Issue
Block a user