Skip to content

Commit ded1b01

Browse files
authored
Merge branch 'master' into openocd-hex
2 parents 13edbe8 + 679758e commit ded1b01

File tree

6 files changed

+16
-9
lines changed

6 files changed

+16
-9
lines changed

Cargo.lock

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

Cargo.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ name = "humility"
1717
#
1818
# Be sure to check in and push all of the files that change. Happy versioning!
1919
#
20-
version = "0.11.9"
20+
version = "0.11.10"
2121
authors = ["Bryan Cantrill <[email protected]>"]
2222
edition = "2018"
2323
license = "MPL-2.0"

cmd/rebootleby/src/lib.rs

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -42,13 +42,20 @@ fn rebootleby(context: &mut ExecutionContext) -> Result<()> {
4242
let mut zip =
4343
ZipArchive::new(bundle_reader).context("opening bundle file as ZIP")?;
4444

45-
let img_bootleby = {
45+
let img_bootleby = if zip.file_names().any(|x| x == "bootleby.bin") {
4646
let mut entry = zip
4747
.by_name("bootleby.bin")
4848
.context("can't find bootleby.bin in bundle")?;
4949
let mut data = vec![];
5050
entry.read_to_end(&mut data).context("reading bootleby.bin")?;
5151
data
52+
} else {
53+
let mut entry = zip
54+
.by_name("img/final.bin")
55+
.context("can't find bootleby.bin or img/final.bin in bundle")?;
56+
let mut data = vec![];
57+
entry.read_to_end(&mut data).context("reading bootleby.bin")?;
58+
data
5259
};
5360
let img_cmpa = {
5461
let mut entry =

tests/cli_tests.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -76,7 +76,7 @@ fn make_tests(tests: &[Test], kind: Kind) -> Result<()> {
7676

7777
if let Some(f) = path.file_name() {
7878
if let Some(s) = f.to_str() {
79-
if let Some(name) = s.strip_prefix(&kind.prefix()) {
79+
if let Some(name) = s.strip_prefix(kind.prefix()) {
8080
input.push((name.to_string(), s.to_string()));
8181
}
8282
}
@@ -112,7 +112,7 @@ fn make_tests(tests: &[Test], kind: Kind) -> Result<()> {
112112
let testcmd = if let Some(arg) = test.arg {
113113
format!("{} {arg}", test.cmd)
114114
} else {
115-
format!("{}", test.cmd)
115+
test.cmd.to_string()
116116
};
117117

118118
writeln!(

tests/cmd/chip.trycmd

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ For more information try --help
1313

1414
```
1515
$ humility --chip this-can-be-anything -V
16-
humility 0.11.9
16+
humility 0.11.10
1717

1818
```
1919

@@ -28,7 +28,7 @@ For more information try --help
2828

2929
```
3030
$ humility -c apx432 -V
31-
humility 0.11.9
31+
humility 0.11.10
3232

3333
```
3434

tests/cmd/version.trycmd

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,14 +2,14 @@ Long version flag:
22

33
```
44
$ humility --version
5-
humility 0.11.9
5+
humility 0.11.10
66

77
```
88

99
Short version flag:
1010

1111
```
1212
$ humility -V
13-
humility 0.11.9
13+
humility 0.11.10
1414

1515
```

0 commit comments

Comments
 (0)