Skip to content

Commit b239603

Browse files
committed
dist-apple: a step owns its id and description; the version literal is 0.9.2
1 parent 3ad808c commit b239603

2 files changed

Lines changed: 9 additions & 6 deletions

File tree

dist/apple.cppm

Lines changed: 8 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -246,9 +246,12 @@ struct options {
246246
// a different signing flag -- from becoming a reimplementation of this
247247
// member, the same trade `dist/appimage.cppm` makes.
248248
struct step {
249-
const char* id;
250-
const char* role;
251-
const char* description;
249+
// Owned strings rather than literals: the resource steps below name one
250+
// action per deployed entry, and an id derived from a file name has to
251+
// outlive the function that formed it.
252+
std::string id;
253+
const char* role;
254+
std::string description;
252255
std::vector<std::string> argv;
253256
std::vector<std::string> inputs;
254257
// MORE THAN ONE OUTPUT ON THE iOS ICON STEP: a directory of PNGs copies
@@ -877,9 +880,9 @@ inline bool submit(const plan& p) {
877880
if (!p.applies) return true;
878881
for (auto const& s : p.steps) {
879882
mcpp::action a;
880-
a.id = s.id;
883+
a.id = s.id.c_str();
881884
a.role = s.role;
882-
a.description = s.description;
885+
a.description = s.description.c_str();
883886
for (auto const& tok : s.argv) a.arg(tok.c_str());
884887
for (auto const& in : s.inputs) a.input(in.c_str());
885888
for (auto const& out : s.outputs) a.output(out.c_str());

src/plugins.cppm

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -49,7 +49,7 @@ export namespace mcpp::plugins {
4949
//
5050
// One package, one version: the number lives in mcpp.toml, and the CI step
5151
// `the collection states its own version` compares the two.
52-
inline constexpr std::string_view version = "0.9.1";
52+
inline constexpr std::string_view version = "0.9.2";
5353

5454
} // namespace mcpp::plugins
5555

0 commit comments

Comments
 (0)