Git Product home page Git Product logo

3mpee3mpee / nvim_dw_sync Goto Github PK

View Code? Open in Web Editor NEW
5.0 1.0 0.0 31 KB

This Neovim plugin facilitates synchronization with Demandware (DW) by providing features to upload files and manage project cleanliness. It integrates with Telescope for a seamless experience.

License: MIT License

Lua 100.00%
demandware lazy-nvim neovim neovim-plugin neovim-plugin-lua neovim-plugins nvim nvim-lua nvim-plugin nvim-plugins salesforce-commerce-cloud neovim-telescope-extension nvim-telescope telescope-extension telescope-plugin

nvim_dw_sync's Introduction

DW Sync Neovim Plugin

This Neovim plugin facilitates synchronization with Demandware (DW) by providing features to upload files and manage project cleanliness. It integrates with Telescope for a seamless experience.

Installation

To install the plugin, you can use your favorite plugin manager for Neovim. Here's an example using Lazy:

return {
  "3mpee3mpee/nvim_dw_sync",
  dependencies = {
    "nvim-telescope/telescope.nvim",
  },
  config = function()
    require("telescope").load_extension("nvim_dw_sync")
    require("nvim_dw_sync").setup({})
  end,

  -- Example keybindings. Adjust these to suit your preferences or remove
  --   them entirely:
  keys = {
    {
      "<Leader>ds",
      ":Telescope nvim_dw_sync open_telescope<CR>",
      desc = "DW Sync open telescope",
    },
  },
}

Configuration

After installing the plugin, you need to set up your DW configuration. Create a dw.json file in the root of your project with the following structure:

{
  "hostname": "your_dw_hostname",
  "code-version": "your_code_version",
  "username": "your_dw_username",
  "password": "your_dw_password"
}

Replace "your_dw_hostname", "your_code_version", "your_dw_username", and "your_dw_password" with your actual DW credentials.

Usage

Once the plugin is installed and configured, you can use the following commands within Neovim:

:Telescope nvim_dw_sync open_telescope OR use the hotkeys you configured.

It will open you new telescope picker window where you are free to use following actions:

  • Clean Project and Upload All
  • Upload Cartridges
  • Clean Project
  • Enable Upload
  • Disable Upload

Clean Project and Upload All

This action will trigger sequence of actions:

  1. Clean Project - completely removes all files from the DW server
  2. Upload Cartridges - uploads all cartridges found on your cwd to the DW server
  3. Enable Upload - enables automatic upload on save / delete / rename file

Upload Cartridges

This action will upload all cartridges found on your cwd to the DW server

Clean Project

This action will completely remove all files from the DW server

Enable Upload

This action will enable automatic upload on save / delete / rename file

Disable Upload

This action will disable automatic upload on save / delete / rename file

Known Issues

Currently there are several known issues with the plugin:

  1. Clean Project and Upload All not working properly sometimes
  2. Upload Cartridges will populate the list of cartridges only once. If you use Enable Upload and for example adding a new cartridge, you will need to run Upload Cartridges again to populate the list of cartridges. This will be solved in the future by adding a new action called Refresh Cartridges.

TODO

  • Add Refresh Cartridges action
  • Fix Clean Project and Upload All action

License

This plugin is licensed under the MIT License. See the LICENSE file for details.

nvim_dw_sync's People

Contributors

3mpee3mpee avatar

Stargazers

Kostya avatar  avatar  avatar Alex Stinky avatar  avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.