0

I'm trying to set up Broswers-Sync for my Aquia Dev Desktop Drupal 7 installation on localhost

In the page tutorial it says to set up local host like this command:

browser-sync start --proxy "myproject.dev" --files "css/*.css"

But I'm not sure what to put in there for my actual project.

The file I want to target is:

C:\patch\sites\all\themes\bootstrap_subtheme_local\css\style.css

And site URL on my machine is:

http://patch.dd:8083/

I want to know what to put in the command line to make this work.

2 Answers 2

1

You need to specify the hostname and port (patch.dd:8083) and the path to the CSS files you want to watch. Using the values in your example, you should therefore run:

browser-sync start --proxy "patch.dd:8083" --files "C:\patch\sites\all\themes\bootstrap_subtheme_local\css\style.css"
1
  • Hi Nic, yes indeed this is working, it DOES open the website in the window, but changing css does nothing after saving, need to refresh...using Notepad++, am I missing something? URL says localhost:3000 so everything should work? Commented Mar 24, 2016 at 9:26
0

Here's the fix, I used...

The problem was that localhost:3000 isn't actually connected to http://yourblogname.dd:8080/- you can verify this by going to localhost:3001 (or the UI port shown on your console) and you should see that while using aquia dev desktop, there is no connection unless you go to yourblogname.dd/3000

To fix this, I've used an external call, that will change the output localhost:3000 to myblogname:3000

gulp.task('browserSync', function() {
    //note: special fix for aquia dev desktop, to get mybog.dd
    browserSync.init({
       open: 'external',
       host: 'yourblogname.dd',
       proxy: 'http://yourblogname.dd:8080/', // or project.dev/app/
   });
});
0

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.