From b5f1280c15df6f9504dba8e290eaf94dfbd12460 Mon Sep 17 00:00:00 2001 From: Alexandre Terrasa Date: Mon, 14 May 2018 14:12:08 -0400 Subject: [PATCH] contrib/sort_downloads: protect README doc units Signed-off-by: Alexandre Terrasa --- contrib/sort_downloads/README.md | 20 +++++++++++--------- 1 file changed, 11 insertions(+), 9 deletions(-) diff --git a/contrib/sort_downloads/README.md b/contrib/sort_downloads/README.md index 0a42ca2..f366b8c 100644 --- a/contrib/sort_downloads/README.md +++ b/contrib/sort_downloads/README.md @@ -46,18 +46,20 @@ Your old hard drive is full and you bought a new one. You now want to copy your If you need more than one configuration, let's say to sort videos, you can use Nit class refinement. Create a separate Nit module next to `src/sort_downloads.nit` named `sort_videos.nit` and use something like: - #!/usr/bin/env nit +~~~nitish +#!/usr/bin/env nit - import sort_downloads +import sort_downloads - redef class Config - redef fun source_dir do return "/media/new-drive/video-downloads" - redef fun dest_dir do return "/media/new-drive/Videos" - redef fun regex_source_dirs do return ["~/Videos", dest_dir] - redef fun elapsed_days do return 0 - end +redef class Config + redef fun source_dir do return "/media/new-drive/video-downloads" + redef fun dest_dir do return "/media/new-drive/Videos" + redef fun regex_source_dirs do return ["~/Videos", dest_dir] + redef fun elapsed_days do return 0 +end - super # this executes the program +super # this executes the program +~~~ ## Sort only older files -- 1.7.9.5