Name | miao-make JSON |
Version |
20230627
JSON |
| download |
home_page | |
Summary | Cargo-like project management tool for working with CMake |
upload_time | 2023-06-27 08:06:15 |
maintainer | |
docs_url | None |
author | |
requires_python | |
license | |
keywords |
cmake
cmakelists
|
VCS |
 |
bugtrack_url |
|
requirements |
No requirements were recorded.
|
Travis-CI |
No Travis.
|
coveralls test coverage |
No coveralls.
|
# Miao
   
<br>
<div align="center">
<img src="miao.png" alt="Miao Logo" width="13%"/>
<p>A Python script for generating CMake files, with a user-friendly, Cargo-like command line interface. (UNDER CONSTRUCTION)</p>
</div>
<br>
---
TODO:
<br>
- ☑ miao new
- ☑ --language
- ☑ --standard
- ☐ --lib
- ☑ miao add
- ☑ --include_dirs
- ☑ --lib_dirs
- ☑ miao build
- ☑ miao run
- ☑ miao clean
- ☑ miao help
- ☐ miao init
- ☐ --lib
- ☐ miao remove
- ☐ miao config
- ☐ --default_language
- ☐ --default_language --standard
- ☐ --default_include_dirs
<br>
## Installation
```bash
# The PyPI version may be outdated.
# Please consider using `git clone` to
# obtain the latest version.
pip3 install miao-make
```
## Usage
- `miao help`
```bash
$ miao help
Miao Version 20230626
add Add dependencies.
Use `--include_dirs` to add header file directories.
Use `--lib_dirs` to add library file directories.
build Compile the current project.
clean Remove the build directory.
config ...
find_project_root
help Print help.
init
new Create a new project.
remove ...
run Run the current project.
version Print version info and exit.
```
- `miao new` - Creating a new project
```bash
# Create a new project
$ miao new my_project
Created my_project
Added CMakelists.txt
(debug) `
set(CMAKE_CXX_STANDARD 17)
file(GLOB_RECURSE SOURCES "src/*.cpp")
`
Created `src/` directory
Added main.cpp
Created `build/` directory
# The `--language` and `--standard` flags
$ miao new 'hello world' --language cpp --standard 20
Created hello_world
Added CMakelists.txt
(debug) ```set(CMAKE_CXX_STANDARD 20)
file(GLOB_RECURSE SOURCES "src/*.cpp")```
Created `src/` directory
Added main.cpp
Created `build/` directory
```
- `miao add` - Adding libraries
Configure header files with `miao add LIB --include_dirs=DIR1,DIR2`
```bash
$ cd my_project/
$ miao add ncurses --include_dirs=$(brew --prefix ncurses)/include
Adding header directories ['/usr/local/opt/ncurses/include']
Adding ('ncurses',) for `my_project`
```
and library files with `--lib_dirs=`
```
$ miao new tui && cd tui/ # Created project called `tui`
$ miao add ftxui-dom ftxui-screen ftxui-component --include_dirs=/usr/local/include,/usr/local/include/ftxui --lib_dirs=/usr/local/lib
Adding ('ftxui-dom', 'ftxui-screen', 'ftxui-component') for `tui`
CMakeLists.txt
find_library(ftxui-dom NAMES ftxui-dom PATHS /usr/local/lib)
find_library(ftxui-screen NAMES ftxui-screen PATHS /usr/local/lib)
find_library(ftxui-component NAMES ftxui-component PATHS /usr/local/lib)
target_include_directories(tui.exe PRIVATE /usr/local/include /usr/local/include/ftxui)
target_link_libraries(tui.exe ${ftxui-dom} ${ftxui-screen} ${ftxui-component})
```
- Run
```bash
$ miao run
root: /Users/4nji/dev/python/miao/src/my_project
pwd: /Users/4nji/dev/python/miao/src/my_project
Entering /Users/4nji/dev/python/miao/src/my_project/build
-- The C compiler identification is AppleClang 13.0.0.13000029
-- The CXX compiler identification is AppleClang 13.0.0.13000029
-- Detecting C compiler ABI info
-- Detecting C compiler ABI info - done
-- Check for working C compiler: /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/cc - skipped
-- Detecting C compile features
-- Detecting C compile features - done
-- Detecting CXX compiler ABI info
-- Detecting CXX compiler ABI info - done
-- Check for working CXX compiler: /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/c++ - skipped
-- Detecting CXX compile features
-- Detecting CXX compile features - done
-- Configuring done (1.5s)
-- Generating done (0.0s)
-- Build files have been written to: /Users/4nji/dev/python/miao/src/my_project/build
Success Successfully executed the command: ['cmake', '/Users/4nji/dev/python/miao/src/my_project']
[ 50%] Building CXX object CMakeFiles/my_project.exe.dir/src/main.cpp.o
[100%] Linking CXX executable my_project.exe
[100%] Built target my_project.exe
Success Successfully executed the command: ['make']
===========================2023-06-24 19:56:20.228994==========================
Running /Users/4nji/dev/python/miao/src/my_project/build/my_project.exe
===============================================================================
Hello, world!
Process finished with exit code 0
```
- Cleaning up
```
$ miao clean
Removing /Users/Me/dev/python/miao/src/hello_world/build
```
Raw data
{
"_id": null,
"home_page": "",
"name": "miao-make",
"maintainer": "",
"docs_url": null,
"requires_python": "",
"maintainer_email": "",
"keywords": "cmake,cmakelists",
"author": "",
"author_email": "Anji Wong <anzhi0708@gmail.com>",
"download_url": "https://files.pythonhosted.org/packages/7a/4e/eda03c46b7b246cddf25f57562cb3a2f5d13bbfe3fc329782d32637af41c/miao-make-20230627.tar.gz",
"platform": null,
"description": "# Miao\n\n   \n\n<br>\n\n<div align=\"center\">\n\n <img src=\"miao.png\" alt=\"Miao Logo\" width=\"13%\"/>\n\n <p>A Python script for generating CMake files, with a user-friendly, Cargo-like command line interface. (UNDER CONSTRUCTION)</p>\n\n</div>\n\n<br>\n\n---\n\nTODO:\n\n<br>\n\n- \u2611 miao new\n - \u2611 --language\n - \u2611 --standard \n - \u2610 --lib\n- \u2611 miao add\n - \u2611 --include_dirs\n - \u2611 --lib_dirs\n- \u2611 miao build\n- \u2611 miao run\n- \u2611 miao clean\n- \u2611 miao help\n- \u2610 miao init\n - \u2610 --lib\n- \u2610 miao remove\n- \u2610 miao config\n - \u2610 --default_language\n - \u2610 --default_language --standard\n - \u2610 --default_include_dirs\n\n<br>\n\n## Installation\n\n```bash\n\n# The PyPI version may be outdated.\n# Please consider using `git clone` to \n# obtain the latest version.\n\npip3 install miao-make\n```\n\n## Usage\n\n- `miao help`\n\n```bash\n$ miao help\n\nMiao Version 20230626\n\n add Add dependencies.\n Use `--include_dirs` to add header file directories.\n Use `--lib_dirs` to add library file directories.\n build Compile the current project.\n clean Remove the build directory.\n config ...\n find_project_root\n help Print help.\n init\n new Create a new project.\n remove ...\n run Run the current project.\n version Print version info and exit.\n\n```\n\n\n- `miao new` - Creating a new project\n\n```bash\n\n# Create a new project\n\n$ miao new my_project\n Created my_project\n Added CMakelists.txt\n (debug) `\n set(CMAKE_CXX_STANDARD 17)\n file(GLOB_RECURSE SOURCES \"src/*.cpp\")\n `\n Created `src/` directory\n Added main.cpp\n Created `build/` directory\n\n\n# The `--language` and `--standard` flags\n\n$ miao new 'hello world' --language cpp --standard 20\n Created hello_world\n Added CMakelists.txt\n (debug) ```set(CMAKE_CXX_STANDARD 20)\n file(GLOB_RECURSE SOURCES \"src/*.cpp\")```\n Created `src/` directory\n Added main.cpp\n Created `build/` directory\n```\n\n\n- `miao add` - Adding libraries\n\nConfigure header files with `miao add LIB --include_dirs=DIR1,DIR2`\n\n```bash\n\n$ cd my_project/\n\n\n$ miao add ncurses --include_dirs=$(brew --prefix ncurses)/include\nAdding header directories ['/usr/local/opt/ncurses/include']\nAdding ('ncurses',) for `my_project`\n\n```\n\nand library files with `--lib_dirs=`\n\n```\n$ miao new tui && cd tui/ # Created project called `tui`\n$ miao add ftxui-dom ftxui-screen ftxui-component --include_dirs=/usr/local/include,/usr/local/include/ftxui --lib_dirs=/usr/local/lib\n\nAdding ('ftxui-dom', 'ftxui-screen', 'ftxui-component') for `tui`\nCMakeLists.txt\nfind_library(ftxui-dom NAMES ftxui-dom PATHS /usr/local/lib)\nfind_library(ftxui-screen NAMES ftxui-screen PATHS /usr/local/lib)\nfind_library(ftxui-component NAMES ftxui-component PATHS /usr/local/lib)\ntarget_include_directories(tui.exe PRIVATE /usr/local/include /usr/local/include/ftxui)\ntarget_link_libraries(tui.exe ${ftxui-dom} ${ftxui-screen} ${ftxui-component})\n```\n\n\n- Run\n\n```bash\n$ miao run\n root: /Users/4nji/dev/python/miao/src/my_project\n pwd: /Users/4nji/dev/python/miao/src/my_project\n Entering /Users/4nji/dev/python/miao/src/my_project/build\n-- The C compiler identification is AppleClang 13.0.0.13000029\n-- The CXX compiler identification is AppleClang 13.0.0.13000029\n-- Detecting C compiler ABI info\n-- Detecting C compiler ABI info - done\n-- Check for working C compiler: /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/cc - skipped\n-- Detecting C compile features\n-- Detecting C compile features - done\n-- Detecting CXX compiler ABI info\n-- Detecting CXX compiler ABI info - done\n-- Check for working CXX compiler: /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/c++ - skipped\n-- Detecting CXX compile features\n-- Detecting CXX compile features - done\n-- Configuring done (1.5s)\n-- Generating done (0.0s)\n-- Build files have been written to: /Users/4nji/dev/python/miao/src/my_project/build\n Success Successfully executed the command: ['cmake', '/Users/4nji/dev/python/miao/src/my_project']\n[ 50%] Building CXX object CMakeFiles/my_project.exe.dir/src/main.cpp.o\n[100%] Linking CXX executable my_project.exe\n[100%] Built target my_project.exe\n Success Successfully executed the command: ['make']\n\n===========================2023-06-24 19:56:20.228994==========================\n\nRunning /Users/4nji/dev/python/miao/src/my_project/build/my_project.exe\n\n===============================================================================\nHello, world!\n\nProcess finished with exit code 0\n\n```\n\n\n- Cleaning up\n\n```\n$ miao clean\nRemoving /Users/Me/dev/python/miao/src/hello_world/build\n\n```\n",
"bugtrack_url": null,
"license": "",
"summary": "Cargo-like project management tool for working with CMake",
"version": "20230627",
"project_urls": {
"Homepage": "https://github.com/anzhi0708/miao"
},
"split_keywords": [
"cmake",
"cmakelists"
],
"urls": [
{
"comment_text": "",
"digests": {
"blake2b_256": "a2ec494599876963661d2bc3db9089049e08c75795487c0faf916b1d6a0b64a7",
"md5": "e38294e9e167b21eb08bfa288ba7910a",
"sha256": "27bd412485f2f96cb8d4b340c1523e24fabcbf2106e784986ca17c6c0986cdf4"
},
"downloads": -1,
"filename": "miao_make-20230627-py3-none-any.whl",
"has_sig": false,
"md5_digest": "e38294e9e167b21eb08bfa288ba7910a",
"packagetype": "bdist_wheel",
"python_version": "py3",
"requires_python": null,
"size": 7696,
"upload_time": "2023-06-27T08:06:12",
"upload_time_iso_8601": "2023-06-27T08:06:12.546108Z",
"url": "https://files.pythonhosted.org/packages/a2/ec/494599876963661d2bc3db9089049e08c75795487c0faf916b1d6a0b64a7/miao_make-20230627-py3-none-any.whl",
"yanked": false,
"yanked_reason": null
},
{
"comment_text": "",
"digests": {
"blake2b_256": "7a4eeda03c46b7b246cddf25f57562cb3a2f5d13bbfe3fc329782d32637af41c",
"md5": "67074a48e16d27c30bf7158308ea02db",
"sha256": "1ee24ebdb883f66468929ee0035de1c8f35c3cf70c1f1ba63acaee50d513e30f"
},
"downloads": -1,
"filename": "miao-make-20230627.tar.gz",
"has_sig": false,
"md5_digest": "67074a48e16d27c30bf7158308ea02db",
"packagetype": "sdist",
"python_version": "source",
"requires_python": null,
"size": 8746,
"upload_time": "2023-06-27T08:06:15",
"upload_time_iso_8601": "2023-06-27T08:06:15.152033Z",
"url": "https://files.pythonhosted.org/packages/7a/4e/eda03c46b7b246cddf25f57562cb3a2f5d13bbfe3fc329782d32637af41c/miao-make-20230627.tar.gz",
"yanked": false,
"yanked_reason": null
}
],
"upload_time": "2023-06-27 08:06:15",
"github": true,
"gitlab": false,
"bitbucket": false,
"codeberg": false,
"github_user": "anzhi0708",
"github_project": "miao",
"travis_ci": false,
"coveralls": false,
"github_actions": false,
"requirements": [],
"lcname": "miao-make"
}