north / generator-style-prototype

Yeoman Generator for Style Prototypes
362 stars 49 forks source link

Incorrect base url / image issues #58

Closed erindepew closed 9 years ago

erindepew commented 10 years ago

@buckie and I were tinkering with the style prototype since I was having issues with gulp deploy. We managed to resolve most of the issues, see https://github.com/Snugug/gulp-subtree/pull/2 and https://github.com/north/gulp-style-prototype/pull/1

The only issue I have left is that the images aren't loading correctly. The issue is that the generated url is (for example) "erindepew.github.io/images/image.jpg" when it actually should be "erindepew.github.io/sso-login_style-prototype/images/image.jpg" I also attached images of the issue.

Also I always have to remove the base-url="/" code line from the .dist/index.html before I build the github page for it to do anything.

I'm digging through the javascript files to see what's generating this base url to try and remove it, which file should I be looking in?

screen shot 2014-06-02 at 9 47 31 am

screen shot 2014-06-02 at 9 47 47 am

buckie commented 10 years ago

Also worth noting the standard install story is wrong. To get Erins to work I needed to install node and Ruby from brew (you have to wipe out the current installs manually) and correct a crap ton of permissions issues with 'chmod -R $USER' to get it to work (also installing gcc may be required for Ruby). If you're using 'sudo npm' ever on a mac you're probably doing it wrong. On Jun 2, 2014 9:59 AM, "Erin" notifications@github.com wrote:

@buckie https://github.com/buckie and I were tinkering with the style prototype since I was having issues with gulp deploy. We managed to resolve most of the issues, see Snugug/gulp-subtree#2 https://github.com/Snugug/gulp-subtree/pull/2 and north/gulp-style-prototype#1 https://github.com/north/gulp-style-prototype/pull/1

The only issue I have left is that the images aren't loading correctly. The issue is that the generated url is (for example) " erindepew.github.io/images/image.jpg" when it actually should be " erindepew.github.io/sso-login_style-prototype/images/image.jpg" I also attached images of the issue.

Also I always have to remove the base-url="/" code line from the .dist/index.html before I build the github page for it to do anything.

I'm digging through the javascript files to see what's generating this base url to try and remove it, which file should I be looking in?

[image: screen shot 2014-06-02 at 9 47 31 am] https://cloud.githubusercontent.com/assets/3421197/3148211/f6adc0b8-ea5d-11e3-902c-c8a52f719add.png

[image: screen shot 2014-06-02 at 9 47 47 am] https://cloud.githubusercontent.com/assets/3421197/3148215/faf4cf5e-ea5d-11e3-9ec8-f171370c1889.png

— Reply to this email directly or view it on GitHub https://github.com/north/generator-style-prototype/issues/58.

Snugug commented 10 years ago

Yah, the install story is wrong and needs to be updated. Docs aren’t done yet.

On Monday, June 2, 2014 at 11:55 AM, buckie wrote:

Also worth noting the standard install story is wrong. To get Erins to work
I needed to install node and Ruby from brew (you have to wipe out the
current installs manually) and correct a crap ton of permissions issues
with 'chmod -R $USER' to get it to work (also installing gcc may be
required for Ruby). If you're using 'sudo npm' ever on a mac you're
probably doing it wrong.
On Jun 2, 2014 9:59 AM, "Erin" <notifications@github.com (mailto:notifications@github.com)> wrote:

@buckie https://github.com/buckie and I were tinkering with the style
prototype since I was having issues with gulp deploy.
We managed to resolve most of the issues, see Snugug/gulp-subtree#2
https://github.com/Snugug/gulp-subtree/pull/2 and
north/gulp-style-prototype#1
https://github.com/north/gulp-style-prototype/pull/1

The only issue I have left is that the images aren't loading correctly.
The issue is that the generated url is (for example) "
erindepew.github.io/images/image.jpg (http://erindepew.github.io/images/image.jpg)" when it actually should be "
erindepew.github.io/sso-login_style-prototype/images/image.jpg (http://erindepew.github.io/sso-login_style-prototype/images/image.jpg)"
I also attached images of the issue.

Also I always have to remove the base-url="/" code line from the
.dist/index.html before I build the github page for it to do anything.

I'm digging through the javascript files to see what's generating this
base url to try and remove it, which file should I be looking in?

[image: screen shot 2014-06-02 at 9 47 31 am]
https://cloud.githubusercontent.com/assets/3421197/3148211/f6adc0b8-ea5d-11e3-902c-c8a52f719add.png

[image: screen shot 2014-06-02 at 9 47 47 am]
https://cloud.githubusercontent.com/assets/3421197/3148215/faf4cf5e-ea5d-11e3-9ec8-f171370c1889.png


Reply to this email directly or view it on GitHub
https://github.com/north/generator-style-prototype/issues/58.

— Reply to this email directly or view it on GitHub (https://github.com/north/generator-style-prototype/issues/58#issuecomment-44862625).

Snugug commented 10 years ago

You also shouldn’t need to chmod anything if you’re doing it through Homebrew

On Monday, June 2, 2014 at 11:55 AM, buckie wrote:

Also worth noting the standard install story is wrong. To get Erins to work
I needed to install node and Ruby from brew (you have to wipe out the
current installs manually) and correct a crap ton of permissions issues
with 'chmod -R $USER' to get it to work (also installing gcc may be
required for Ruby). If you're using 'sudo npm' ever on a mac you're
probably doing it wrong.
On Jun 2, 2014 9:59 AM, "Erin" <notifications@github.com (mailto:notifications@github.com)> wrote:

@buckie https://github.com/buckie and I were tinkering with the style
prototype since I was having issues with gulp deploy.
We managed to resolve most of the issues, see Snugug/gulp-subtree#2
https://github.com/Snugug/gulp-subtree/pull/2 and
north/gulp-style-prototype#1
https://github.com/north/gulp-style-prototype/pull/1

The only issue I have left is that the images aren't loading correctly.
The issue is that the generated url is (for example) "
erindepew.github.io/images/image.jpg (http://erindepew.github.io/images/image.jpg)" when it actually should be "
erindepew.github.io/sso-login_style-prototype/images/image.jpg (http://erindepew.github.io/sso-login_style-prototype/images/image.jpg)"
I also attached images of the issue.

Also I always have to remove the base-url="/" code line from the
.dist/index.html before I build the github page for it to do anything.

I'm digging through the javascript files to see what's generating this
base url to try and remove it, which file should I be looking in?

[image: screen shot 2014-06-02 at 9 47 31 am]
https://cloud.githubusercontent.com/assets/3421197/3148211/f6adc0b8-ea5d-11e3-902c-c8a52f719add.png

[image: screen shot 2014-06-02 at 9 47 47 am]
https://cloud.githubusercontent.com/assets/3421197/3148215/faf4cf5e-ea5d-11e3-9ec8-f171370c1889.png


Reply to this email directly or view it on GitHub
https://github.com/north/generator-style-prototype/issues/58.

— Reply to this email directly or view it on GitHub (https://github.com/north/generator-style-prototype/issues/58#issuecomment-44862625).

buckie commented 10 years ago

Previous installs had screwed the permissions. For example, the her log locations we root only (caused brew to fail). Also, node modules were root owned. Your users are not system administrators or, even back-ends, they will immediately use sudo when the first install doesn't work.

Brew will cowardly refuse to use the crutch known as sudo, which is why it's awesome. I'd suggest making a recipe (or a shell script) to cover this.

Overall nice work.

Snugug commented 10 years ago

Is this still an issue with 2.0 version of Style Prototypes?

erindepew commented 10 years ago

I haven't been able to get gulp deploy to work recently, so I have nothing to check in the gh-pages branch (it displays everything but the actual components: http://erindepew.github.io/sso-login_style-prototype) But I think this is still an issue.

Snugug commented 10 years ago

Unfortunately I can't see the source code, although it appears as if you need to update to the latest version of Style Prototypes. If you do not have a deploy.yml file in your config folder, make one based on the core file, ensuring your remote is correct (probably origin, may not be though)

erindepew commented 10 years ago

Updated, but had this error when I did the bower updates "bower ENOTINS Package style-prototypes is not installed" and I think that the npm updates failed silently. I do have a deploy.yml file in my config folder with the appropriate variables. deployment to gh-pages is still failing.

Snugug commented 10 years ago

Try bower install style-prototypes from your project