A simple and easy project generator for Windows, Mac, and Linux.
If you are trying to slack off on work, proyekgen might be your option! With this program, it gets the job done, creating the source files and everything.
Basically, you'll tell proyekgen to generate a project by using a format.
The format is called a template, it's a set of project files, post-execute scripts, and information for the kind of project you want.
Templates are also extensible and manageable, meaning you can import and export them in the following paths:
Windows | Unix |
---|---|
%AppData%\proyekgen\templates |
$HOME/.local/share/proyekgen/templates |
%ProgramData%\proyekgen\templates |
/var/lib/proyekgen/templates |
Note for UNIX users: $HOME/.proyekgen/templates
wll be used instead of $HOME/.local/share/proyekgen/templates
if XDG dir utilities are not installed
Generate a project by using a template:
$ proyekgen cmake-cpp
By default, proyekgen generates the project inside the current directory.
To use a different directory, pass the -o
or --output
option through command-line arguments:
$ proyekgen <TEMPLATE> -o mydir
$ proyekgen <TEMPLATE> --output mydir # alternative option
Note: proyekgen will result in a fatal error if
the directory doesn't exist. Pass the -m
or --mkdir
option to create it.
You can get the list of installed templates using the -l
option:
$ proyekgen -l
There are 5 templates currently installed:
cmake-c (CMake with C project)
cmake-cpp (CMake with C++ project)
makefile-c (Makefile with C project)
makefile-cpp (Makefile with C++ project)
python (Simple Python project)
or user-specific installed templates:
$ proyekgen -l --user
There are 1 templates currently installed:
python (Simple Python project)
Debug | Release | |
---|---|---|
Windows 64-bit | windows-x64-debug |
windows-x64-release |
Windows 32-bit | windows-x86-debug |
windows-x86-release |
Linux 64-bit | linux-x64-debug |
linux-x64-release |
Linux 32-bit | linux-x86-debug |
linux-x86-release |
Linux armv7* | linux-armv7-debug |
linux-armv7-release |
If you don't use these configurations, build/packaging errors might show up unexpectedly.
Notes:
-
- The build configuration
Linux armv7
is used for building proyekgen inside Termux, see Building on Termux section.
- The build configuration
- Must have a C++ compiler installed (e.g MSVC, GCC, Clang)
- Must have CMake installed (version 3.21 and up)
- Must have the following libraries installed/or built:
- cxxopts
- nlohmann-json
- libarchive
- libconfig
- fmt
If you are building on Windows, you can install the libraries by using Conan or vcpkg
- Configure to make cache first:
$ cd <path/to/proyekgen>
$ cmake -S . -B build/<configuration>
- Then build to generate executable:
$ cmake --build build/<configuration>
For more info on <configuration>
, see the Configurations table.
proyekgen uses CPack to package itself and integrates well with CMake. Before proceeding to package, make sure you have the project configured and built the executable.
A basic example of packaging the binary would be:
$ cd <path/to/build>
$ cpack --config CPackConfig.cmake
The command above calls cpack
, then packages the binary for the current platform.
You can also specify a different or multiple generators:
$ cpack --config CPackConfig.cmake -G NSIS # NSIS installer only
$ cpack --config CPackConfig.cmake -G ZIP # ZIP file only
$ cpack --config CPackConfig.cmake -G "RPM;DEB" # RPM and DEB files
Or, if you want to package the source code and not the binary:
$ cpack --config CPackSourceConfig.cmake
Note: Some CPack generators (like NSIS and WiX) might be unavailable for source packages.
- Install the
proot-distro
package and install a distribution:
$ pkg install proot-distro
...
$ proot-distro install arch
Note: arch
can be replaced with another distribution, pass the list
command to get list of available distributions.
- Enter the PRooted environment and install packages:
$ proot-distro login arch
...
# Logged inside Arch Linux
...
$ pacman -Syu # optional
$ pacman -S base-devel git cmake cxxopts nlohmann-json libarchive libconfig fmt
Notes:
-
- The package names may vary from the distribution you chose, refer to the documentation for finding the equivalent names.
- The distribution you're using might not provide some of the libraries. Use Arch Linux instead.
-
Clone the repository:
$ git clone https://github.com/spirothdev/proyekgen.git
- Follow build instructions to compile.
TODO
TODO
proyekgen is licensed under the GNU Public License v3, feel free to use it in other programs.