0.7.0 • Published 2 years ago

mycashflow-sync v0.7.0

Weekly downloads
55
License
MIT
Repository
-
Last release
2 years ago

MyCashflow Sync

Synchronizes MyCashflow theme files over FTP automatically, refreshing the browser after every CSS/HTML/JS change.

Minimum required Node version >= 10!


Global Installation

npx is the recommended way to use mycashflow-sync, but you can also install it globally:

sudo npm install -g mycashflow-sync

Updating

sudo npm update -g mycashflow-sync

Usage

  1. Enable the Web Designer extension in your shop
  2. Create an empty directory or cd into an existing one
  3. Run the init script to generate a config for the directory
  4. Happy syncing!

Like this...

0. mkdir theme-directory
1. cd theme-directory
2. npx mycashflow-sync init
3. npx mycashflow-sync [sync|watch]

Notes

Make sure that the development mode is on in your templates!

{MinifyCSS(files: ..., mode: 'development')}

Commands

Initialization

Initializes a new configuration file inside the current directory.

npx mycashflow-sync init

Sync

Non-destructive, i.e. will NOT remove any files, but keeps only the newer file.

Syncs the files between the local and the remote machines.

npx mycashflow-sync sync

Watch

Syncs local changes to the remote machine automatically.

npx mycashflow-sync watch

Configuration

You can configure the syncing through sync.json.

Example config

{
  "ftp": {
    "host": "ftp.mycashflow.fi",
    "port": 21,
    "user": "<username>",
    "pass": "<password>"
  },
  "sync": {
    "url": "<shop url>",
    "path": "<remote path>",
    "ignore": [
      "./ignored/directory",
      "./*.scss",
      "./*.css.map"
    ]
  },
  "sass": {
    "source": "scss",
    "dest": "css"
  }
}

Sass paths are optional, and Sass files won't be compiled if you don't provide the Sass paths.

FTP settings

You can find these settings on your shop's Web Designer extension admin page.

OptionDescription
hostFTP server hostname
portFTP server port
userFTP server username
passFTP server password

Sync settings

Make sure your shop version is using the theme directory defined in the remote path.

OptionDescription
urlShop's URL
pathShop's theme path
ignorePatterns to ignore
0.6.7

2 years ago

0.6.6

2 years ago

0.6.9

2 years ago

0.6.8

2 years ago

0.7.0

2 years ago

0.6.5

3 years ago

0.6.4

3 years ago

0.6.3

3 years ago

0.6.2

3 years ago

0.6.1

4 years ago

0.6.0

4 years ago

0.5.4

4 years ago

0.5.3

4 years ago

0.5.0

4 years ago

0.5.2

4 years ago

0.5.1

4 years ago

0.4.4

5 years ago

0.4.3

5 years ago

0.4.2

5 years ago

0.4.1

5 years ago

0.4.0

5 years ago

0.3.2

6 years ago

0.3.1

6 years ago

0.3.0

7 years ago

0.2.2

8 years ago

0.2.1

8 years ago

0.2.0

8 years ago

0.1.7

8 years ago

0.1.6

8 years ago

0.1.5

8 years ago

0.1.4

8 years ago

0.1.3

8 years ago

0.1.2

8 years ago

0.1.1

8 years ago

0.1.0

8 years ago