import-modules 0.1.1

import-all is a crate that enhances the ease of importing modules using regex patterns. It is based on the npm package require-all.
Documentation

import-modules

Description

import-all is a crate that enhances the ease of importing modules using regex patterns. It is based on the npm package require-all.

Usage

use import_modules::import_pub_modules;

import_pub_modules!("tests/pub_modules/", "^((?!mod.rs).)*$");
// Equivalent to:
// pub mod a.rs;
//

Authors

Version History

  • 0.1.1

    • The problem fixed: If the last slash was not included in the directory path, it would cause an error.
  • 0.1

    • First release

License

This project is licensed under the MIT license.