Skip to content

Commit 2864bbd

Browse files
committed
ls command rework
1 parent 740ff04 commit 2864bbd

File tree

3 files changed

+5
-135
lines changed

3 files changed

+5
-135
lines changed

src/bin/ls/help

Lines changed: 0 additions & 134 deletions
This file was deleted.

src/bin/ls/main.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ use rustix::{
99
use std::io::{BufWriter, Stdout, Write, stdout};
1010

1111
const VERSION: &str = coreutils::version_text!("ls");
12-
const HELP: &str = include_str!("./help");
12+
const HELP: &str = coreutils::help_text!(Deep, "ls");
1313
const CURRENT_DIR_PATH: &str = ".";
1414

1515
fn main() -> Result {

src/lib.rs

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -69,4 +69,8 @@ macro_rules! help_text {
6969
($name: literal) => {
7070
include_str!(concat!("../../docs/", $name, ".txt"))
7171
};
72+
73+
(Deep, $name: literal) => {
74+
include_str!(concat!("../../../docs/", $name, ".txt"))
75+
};
7276
}

0 commit comments

Comments
 (0)