Add generic targets for VIM // Issue #427

This commit is contained in:
Ivan Kravets
2016-01-05 02:26:37 +02:00
parent df099e15c0
commit 33543d6d8f
5 changed files with 27 additions and 5 deletions

View File

@ -7,8 +7,8 @@ PlatformIO 2.0
2.7.1 (2016-01-??) 2.7.1 (2016-01-??)
~~~~~~~~~~~~~~~~~~ ~~~~~~~~~~~~~~~~~~
* Added generic targets for Eclipse IDE, Emacs, Sublime Text: Build, Clean, * Added generic targets for CLion, Eclipse IDE, Emacs, Sublime Text, VIM: Build,
Upload, Upload SPIFFS image, Upload using Programmer, Update installed Clean, Upload, Upload SPIFFS image, Upload using Programmer, Update installed
platforms and libraries platforms and libraries
(`issue #427 <https://github.com/platformio/platformio/issues/427>`_) (`issue #427 <https://github.com/platformio/platformio/issues/427>`_)
* Updated Teensy Arduino Framework to 1.26 * Updated Teensy Arduino Framework to 1.26

View File

@ -58,7 +58,7 @@ the screenshot below):
* ``PLATFORMIO_CLEAN`` - Clean compiled objects. * ``PLATFORMIO_CLEAN`` - Clean compiled objects.
* ``PLATFORMIO_PROGRAM`` - Build and upload using external programmer (if no errors), see :ref:`atmelavr_upload_via_programmer`. * ``PLATFORMIO_PROGRAM`` - Build and upload using external programmer (if no errors), see :ref:`atmelavr_upload_via_programmer`.
* ``PLATFORMIO_UPLOADFS`` - Upload files to file system SPIFFS, see :ref:`platform_espressif_uploadfs`. * ``PLATFORMIO_UPLOADFS`` - Upload files to file system SPIFFS, see :ref:`platform_espressif_uploadfs`.
* ``PLATFORMIO_UPDATE`` - Update installed platforms and libraries. * ``PLATFORMIO_UPDATE`` - Update installed platforms and libraries via :ref:`cmd_update`.
.. warning:: .. warning::
The libraries which are added, installed or used in the project The libraries which are added, installed or used in the project

View File

@ -61,7 +61,7 @@ Then:
+ ``PlatformIO: Upload`` - Build and upload (if no errors) + ``PlatformIO: Upload`` - Build and upload (if no errors)
+ ``PlatformIO: Upload using Programmer`` see :ref:`atmelavr_upload_via_programmer` + ``PlatformIO: Upload using Programmer`` see :ref:`atmelavr_upload_via_programmer`
+ ``PlatformIO: Upload SPIFFS image`` see :ref:`platform_espressif_uploadfs` + ``PlatformIO: Upload SPIFFS image`` see :ref:`platform_espressif_uploadfs`
+ ``PlatformIO: Update platforms and libraries`` - Update installed platforms and libraries + ``PlatformIO: Update platforms and libraries`` - Update installed platforms and libraries via :ref:`cmd_update`.
If you have some problems with unresolved includes, defines, etc., then If you have some problems with unresolved includes, defines, etc., then

View File

@ -58,7 +58,7 @@ Also, you can access to all pre-configured targets via
+ ``PlatformIO - Upload`` - Build and upload (if no errors) + ``PlatformIO - Upload`` - Build and upload (if no errors)
+ ``PlatformIO - Upload using Programmer`` see :ref:`atmelavr_upload_via_programmer` + ``PlatformIO - Upload using Programmer`` see :ref:`atmelavr_upload_via_programmer`
+ ``PlatformIO - Upload SPIFFS image`` see :ref:`platform_espressif_uploadfs` + ``PlatformIO - Upload SPIFFS image`` see :ref:`platform_espressif_uploadfs`
+ ``PlatformIO - Update platforms and libraries`` - Update installed platforms and libraries + ``PlatformIO - Update platforms and libraries`` - Update installed platforms and libraries via :ref:`cmd_update`.
Manual Integration Manual Integration
^^^^^^^^^^^^^^^^^^ ^^^^^^^^^^^^^^^^^^

View File

@ -48,11 +48,33 @@ Put to the project directory ``Makefile`` wrapper with contents:
#PATH := /usr/local/bin:$(PATH) #PATH := /usr/local/bin:$(PATH)
all: all:
platformio -f -c vim run
upload:
platformio -f -c vim run --target upload platformio -f -c vim run --target upload
clean: clean:
platformio -f -c vim run --target clean platformio -f -c vim run --target clean
program:
platformio -f -c vim run --target program
uploadfs:
platformio -f -c vim run --target uploadfs
update:
platformio -f -c vim update
Pre-defined targets:
+ ``Build`` - Build project without auto-uploading
+ ``Clean`` - Clean compiled objects.
+ ``Upload`` - Build and upload (if no errors)
+ ``Upload using Programmer`` see :ref:`atmelavr_upload_via_programmer`
+ ``Upload SPIFFS image`` see :ref:`platform_espressif_uploadfs`
+ ``Update platforms and libraries`` - Update installed platforms and libraries via :ref:`cmd_update`.
Now, in VIM ``cd /path/to/this/project`` and press ``Ctrl+B`` or ``Cmd+B`` Now, in VIM ``cd /path/to/this/project`` and press ``Ctrl+B`` or ``Cmd+B``
(Mac). *PlatformIO* should compile your source code from the ``src`` directory, (Mac). *PlatformIO* should compile your source code from the ``src`` directory,