How to Contribute




Contibute Procedure
  1. Clone the repository from pit-ray/win-vind. For example, you do a follow command.
  2. $git clone https://github.com/pit-ray/win-vind.git

  3. Make a unique branch for pull requests.
  4. $git checkout -b UNIQUE_BRANCH_NAME

  5. You can do something for this project.
  6. Build project for release in root directory.
  7. $./push_preproc.bat 0.0.0

  8. Please add, commit and push.
  9. $git add .

    $git commit -m "Please write a summary of your changes."

    $git push origin UNIQUE_BRANCH_NAME

  10. Please send pull requests at Pull requests pit-ray/win-vind

Note

Development Environment

You must install follow softwares or libraries.

Name Minimum Version Download Link
MinGW-w64 GCC-8.1.0-x86_64-posix-seh MinGW-w64 SourceForge.net
CMake 3.14.4 Download - CMake
wxWidgets 3.0.5 Downloads - wxWidgets
NSIS 3.06.1 Download - NSIS

This project use <mutex>, so some MinGW without it will fail a build. In this case, you will need to install other MinGW with . (select posix at item called Thread in MinGW-Installer.)


Build Instruction

Class Information

There are six base classes in win-vind as follow.

Pure Base Class
Base Class With Creator
Function Examples
KeyBinding
KeyBindingWithCreator
d->d, h, j, k, l
Command
CommandWithCreator
:exit, :close, :mkdir
DynamicOption
DynamicOptionWithCreator
Autotrack Popup

With Creator means having some factory functions. If you make some new functions, you must register to include/system/key_binder_list.hpp, so I recommend to use With Creator base classes in order to register easily.

New KeyBinding Example
  1. Make a new derived class (e.g. MyBinding) and add files into system/***_bindings/.
  2. my_binding.hpp

    #ifndef _TEST_BINDING_HPP
    #define _TEST_BINDING_HPP
    #include "key_binding_with_creator.hpp"
    
    struct MyBinding : public KeyBindingWithCreator<MyBinding>
    {
        static bool sprocess(const bool first_call) ;
        static const std::string sname() noexcept ;
    } ;
    #endif
    

    my_binding.cpp

    #include "my_binding.hpp"
    
    const std::string MyBinding::sname() noexcept
    {
        return "my_binding" ;
    }
    bool MyBinding::sprocess(const bool first_call)
    {
        //Do something
        return true ;
    }
    
  3. You must register MyBinding to include/system/key_binder_list.hpp
  4. Please add the unique identifier to default_config/bindings.json.
  5. {
        "name": "my_binding",
        "key": ["q->c"],
        "cmd": [],
        "en": "My Binding"
    }