Skip to content

AlexandrAnatoliev/jvim-plugins

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

595 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Simple Vim Plugins In Java

Created for educational purposes to test interaction between Vim and Java

EN RU Version 0.8.44 Stars Forks GitHub repo size

Author: Alexandr Anatoliev

GitHub: AlexandrAnatoliev


Table of Contents


Plugin Installation

  • Clone the plugins repository:
git clone https://github.com/AlexandrAnatoliev/jvim-plugins 
  • Navigate to the root:
cd jvim-plugins/
  • Make the scripts executable:
chmod +x *.sh

Install the plugin using the script:

./install.sh [plugin]
  • When installing a plugin, it is installed in the appropriate Vim directory.
~/.vim/
└── pack/
    └── my-plugins/
        └── start/
            └── jvim-example-plugin/
  • Reload Vim or execute a command:
:source ~/.vim/pack/my-plugins/start/jvim-example-plugin/plugin/jvim_example_plugin.vim

Plugin Uninstallation

  • To uninstall the plugin using the script:
./remove.sh [plugin]

Files Structure

jvim-plugins 
├── install.sh
├── pom.xml
├── pomodoro
├── README.md
├── remove.sh
└── vimstat

Plugin List

Pomodoro Plugin

pomodoro - Simple Vim pomodoro plugin.

Use Vim to edit files, and after 25 minutes it will change Vim's color scheme to remind you to take a break. Designed for self-monitoring and productivity.

./install.sh pomodoro

Vim stats plugin

vimstat - Vim utility to get stats.

  • After closing Vim, you will see:
    =======================================
                    Vim stats:
    ---------------------------------------
    - today:             0 h 23 min 31 sec
    - average:           0 h 37 min 10 sec
    - today:    1 commits   100++    105--
    - average:  0 commits    23++     10--
    =======================================

Designed for self-monitoring and productivity.

./install.sh vimstat

Contributing

Setup Instructions

  1. Fork this repository by clicking on the "Fork" button at the top-right corner of this page. This creates a copy of the repository in your GitHub account.

  2. Clone your forked repository by clicking the "Code" button. That will open small window. In it you can copy and paste the URL to your local machine with the command:

git clone https://github.com/<your-username>/jvim-plugins.git
  1. Navigate to your project folder:
cd jvim-plugins
  1. Add a reference to the original repository for future updates:
git remote add upstream https://github.com/AlexandrAnatoliev/jvim-plugins.git

(Remember to keep here the original repository URL, not your forked one, so the username in this needs to be AlexandrAnatoliev, not your own username.)

  1. Check the remotes for your local repository:
git remote -v

You should now see the origin (added automatically when cloning) and upstream remotes listed.

origin  https://github.com/<your-username>/jvim-plugins.git (fetch)
origin  https://github.com/<your-username>/jvim-plugins.git (push)
upstream        https://github.com/AlexandrAnatoliev/jvim-plugins.git (fetch)
upstream        https://github.com/AlexandrAnatoliev/jvim-plugins.git (push)
  1. Pull from the upstream repository to your master branch to keep it in sync with the main project:
git pull upstream master
  1. Create a new branch with the command:
git switch -c fix-issue

Now you are ready to start working on the issues! Remember to pull from the upstream repository every once in a while to keep your local repository up to date with the main project.

Note: I recommend to always create new branch with each Issue you solve! Otherwise, the pull requests will get too large and there could be merge conflicts.

Submitting Your Changes

Once you've made the necessary changes to fix the issue, you're ready to submit your changes!

  1. Apply the style checker:
mvn -f [plugin-name] spotless:apply
  1. Stage your changes with the command:
git add files-that-you-changed
  1. Commit your changes with the command:
git commit -m "Fixed issue"
  1. Push your changes to your forked repository with the command:
git push origin fix-issue

Once you've pushed your changes to GitHub, you're ready to create a pull request. Go to your forked repository on GitHub.

  • You should see message "fix-issue had recent pushes" (or whatever your branch name is) and button "Compare & pull request" next to it.

  • Click the "Compare & pull request" button to proceed to the pull request page of the original jvim-plugins repository.

  • Fill in the title and description boxes with details about the problem and how you got it to work. You can also add some additional information such as screenshots, if you want.

  • Finally, click "Create pull request" to finish creating the pull request.

Congratulations on making your open source contribution on my GitHub project!

Sit back and wait for feedback on the pull request. If everything is fine, you should get the pull request merged. If not, you will be requested to make changes to your code.

Remember to wait for me to review your pull request, do not close it yourself. If you are asked to make changes, you can do so by committing them to the same branch, there is no need to close the current Pull Request and open a new one.


Contact

For any queries, feel free to open an issue, write to Discussions or reach out to me at per-1986@list.ru.


Requirements

  • Java installed
  • Vim installed
  • Maven installed

Compatibility

  • Vim 7.0 and above
  • Java 8 and above
  • Maven 3 and above

Простые плагины для Vim на языке Java

Пишу их в учебных целях для проверки взаимодействия Vim и Java

EN RU Version 0.8.44 Stars Forks GitHub repo size


Оглавление


Установка

  • Клонируйте репозиторий:
git clone https://github.com/AlexandrAnatoliev/jvim-plugins 
  • Перейдите в корневую директорию:
cd jvim-plugins/
  • Сделайте скрипты исполняемыми:
chmod +x *.sh

Установите плагин с помощью скрипта:

./install.sh [plugin]
  • При установке плагин помещается в соответствующую директорию Vim.
~/.vim/
└── pack/
    └── my-plugins/
        └── start/
            └── jvim-example-plugin/
  • Перезагрузите Vim или выполните команду:
:source ~/.vim/pack/my-plugins/start/jvim-example-plugin/plugin/jvim_example_plugin.vim

Удаление плагина

  • Для удаления плагина используйте скрипт:
./remove.sh [plugin]

Структура файлов

jvim-plugins 
├── install.sh
├── pom.xml
├── pomodoro
├── README.md
├── remove.sh
└── vimstat

Список плагинов

Pomodoro Плагин

pomodoro - Простой Pomodoro плагин для Vim.

Используйте Vim для редактирования файлов и через 25 минут он изменит цветовую схему Vim, чтобы напомнить вам о необходимости сделать перерыв. Разработан для самоконтроля и эффективности.

Vim Stats Плагин

vimstat - Простой плагин для измерения статистики работы Vim.

По окончании работы и закрытия Vim будет выведено:

    =======================================
                    Vim stats:
    ---------------------------------------
    - today:             0 h 23 min 31 sec
    - average:           0 h 37 min 10 sec
    - today:    1 commits   100++    105--
    - average:  0 commits    23++     10--
    =======================================

Нужен для самоконтроля и производительности.

./install.sh vimstat

Участие В Разработке

Инструкции по Установке

  1. Сделайте "форк" этого репозитория нажатием кнопки "Fork" в правом верхнем углу страницы. Это создаст копию репозитория на Вашем GitHub аккаунте.

  2. Клонируйте Ваш "форк" репозиторий нажатием кнопки "Code". Откроется маленькое окно. Скопируйте из него URL и выполните на своем компьютере команду:

git clone https://github.com/<your-username>/jvim-plugins.git
  1. Перейдите в папку с проектом:
cd jvim-plugins
  1. Добавьте ссылку на оригинальный репозиторий для будущих обновлений:
git remote add upstream https://github.com/AlexandrAnatoliev/jvim-plugins.git

(Напомню, здесь должен быть URL оригинального репозитория, а не "форкнутого" Вами, так что username в нем должно быть AlexandrAnatoliev, а не Ваш собственный username.)

  1. Проверьте ремоуты для своего репозитория:
git remote -v

Вы должны увидеть origin (добавляется автоматически при клонировании) и upstream ремоуты:

origin  https://github.com/<your-username>/jvim-plugins.git (fetch)
origin  https://github.com/<your-username>/jvim-plugins.git (push)
upstream        https://github.com/AlexandrAnatoliev/jvim-plugins.git (fetch)
upstream        https://github.com/AlexandrAnatoliev/jvim-plugins.git (push)
  1. Выполните pull из upstream репозитория в Вашу master ветку, чтобы синхронизировать ее с основным проектом:
git pull upstream master
  1. Создайте новую ветку командой:
git switch -c fix-issue

Сейчас Вы готовы начать работать с issue! Помните, каждый раз сначала делать pull из upstream репозитория, чтобы держать содержимое Вашего локального репозитория в соответствии с главным проектом.

Примечание: Рекомендую всегда создавать новую ветвь для каждого issue, который Вы выполняете! Иначе pull request будут слишком большими и возможно возникнут конфликты слияния.

Отправка Ваших изменений

После того как Вы решили задачу, Вы готовы отправить изменения!

  1. Примените стайл-чекер:
mvn -f [plugin-name] spotless:apply
  1. Добавьте Ваши изменения в отслеживание:
git add files-that-you-changed
  1. Сделайте коммит:
git commit -m "Fixed issue"
  1. Отправить изменения в Ваш "форк" репозиторий:
git push origin fix-issue

После того как Вы отправили Ваши изменения на GitHub, Вы готовы создать pull request. Перейдите на Ваш "форк" репозитория на GitHub.

  • Вы увидите надпись "fix-issue had recent pushes" (или как Ваша ветка называется) и кнопку "Compare & pull request" на ней.

  • Нажмите кнопку "Compare & pull request" и перейдете на страницу pull request оригинального репозитория проекта jvim-plugins.

  • Заполните поля title и description подробностямм о задаче и Вашем ее решении. Вы можете также добавить иную информацию, такую как скриншоты, если хотите.

  • В конце нажмите кнопку "Create pull request" чтобы закончить создание pull request.

Поздравляю, Вы сделали свой вклад в мой open source проект!

Можете расслабиться и подождать пока не сделают ревью Вашего кода. Если все хорошо, Ваш pull будет принят в основную ветку. Если нет, Вам будет предложено внести изменения в Ваш код.

Помните, что нужно подождать ревью Вашего pull request, не закрывайте его сами. Если Вас просят сделать изменения, Вы можете коммититить их в ну же самую ветвь, не нужно закрывать текущий pull request и открывать новый.


Контакты

Столкнувшись с затруднениями, не стесняйтесь открыть issue, написать в Discussions или мне на почту per-1986@list.ru.


Требования

  • Установленная Java
  • Установленный Vim
  • Установленный Maven

Совместимость

  • Vim 7.0 и выше
  • Java 8 и выше
  • Maven 3 и выше

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors