I just encountered something rather odd.

I installed bootstrap_sass via CLI, followed the instructions given on drupal.org/project/bootstrap_sass, after it was completed, I ran gulp as it instructs

$ gulp
[14:17:21] Using gulpfile [MY_PATH]/web/themes/contrib/bootstrap_sass/gulpfile.js
[14:17:21] Starting 'default'...
[14:17:21] Starting 'styles'...
[14:17:28] Finished 'styles' after 6.71 s
[14:17:28] Starting 'js'...
[14:17:28] Starting 'serve'...
[Browsersync] Proxying: http://yourdomain.com
[Browsersync] Access URLs:
 ------------------------------------
       Local: http://localhost:3000
    External: http://192.168.1.8:3000
 ------------------------------------
          UI: http://localhost:3001
 UI External: http://localhost:3001
 ------------------------------------
[Browsersync] 5 files changed (bootstrap.min.js, jquery.min.js, popper.min.js, popper.min.js.map, barrio.js)
[14:17:29] Finished 'js' after 846 ms
[Browsersync] Reloading Browsers... (buffered 5 events)

When yourdomain.com attempts to come up, it redirects to yoursite.com, which causes the launched window to bring up a completely unrelated WORDPRESS website. I have confirmed this by manually entering yourdomain.com into a separate browser tab. Checking, I find that browsersync is calling "yourdomain.com" as a proxy on line 81 of the included gulpfile.js

In checking, the project page does state:

Installation

    Install node.js on your server
    On the theme´s folder:
    Install gulp: npm install --global gulp-cli
    Install dependencies including Bootstrap latest version: npm install
    Change permissions to node modules folderchmod -R u+x node_modules
    Optional install Material Design Bootstrap: npm install mdbootstrap

Update line#47 of the gulpfile.js file with your own domain.

browserSync.init({
  proxy: "http://yourdomain.com",
});

This will generate a style.css file with mappings for debbuging and a style.min.css file for production. You will need to change the reference to the file manually on your SUBTHEME.libraries.yml file.
Execution

Just run gulp

However, line 47 is a path statement pointing to the theme folder, so it is most likely going to be correct. The code referenced above, which needs to be changed is lines 80-82.

Command icon Show commands

Start within a Git clone of the project using the version control instructions.

Or, if you do not have SSH keys set up on git.drupalcode.org:

Comments

BEGRAFX created an issue. See original summary.

sébastien-fr’s picture

Hello, This is not a bug, you must replace in gulp.js the example of a domain name with your domain. I think it's not really a good idea to have put http://yourdomain.com as an example because this domain already exists. Simply replace it with your local dev domain before launching Gulp for the first time.

begrafx’s picture

Agreed. I thought it odd that a DRUPAL theme ends up bringing up a WordPress website. I would think that for demo purposes, the developers would want to use either https://www.drupal.org/project/bootstrap_sass or https://www.drupal.org or perhaps https://www.drupal.org/project/bootstrap_barrio. Any of these would be a better option than the WordPress site it is using.

  • hatuhay authored ba07e63 on 5.x
    Issue #3195922 by vinyl_roads: Problem with GULPFILE.JS
    
hatuhay’s picture

Status: Active » Fixed

Status: Fixed » Closed (fixed)

Automatically closed - issue fixed for 2 weeks with no activity.

Tokoh’s picture

I'm keen to use this theme and have followed the installation instructions at https://www.drupal.org/project/bootstrap_sass.
But when I entered command gulp, gulp could not find a gulpfile.
The instruction say to alter line 47 of the gulpfile, but where is the appropriate gulpfile?
I have examined the project downloads and although they both contain gulpfiles there are no instructions as the how these download files are to be used, their file entries conflict with the folder system already established and neither the 8.x nor 5.x downloads feature entries like...

browserSync.init({
proxy: "http://yourdomain.com",
});

...or anything like it on line 47.

Have some of the instructions been purged?
Can someone please tell me where the appropriate gulpfile is to be found?

michellesfrazer made their first commit to this issue’s fork.