Grow your CSS skills. Land your dream job.

how do you compile LESS -> on a live WordPress site?

  • # January 24, 2013 at 12:02 am

    I’ve been making good progress with LESS this week. I’ve been using /localhost/ to develop a WordPress theme and the Less.app to compile the CSS every time I save.

    … But then today, I pushed my WordPress site to a live server. I tried to make some style changes on the live site and naturally the LESS won’t compile. I realized I didn’t know how any of that would work in a live environment.

    Could someone explain a bit?

    # January 24, 2013 at 3:23 am

    Generally, you continue to develop locally, and upload changes as they are ready. So you don’t compile LESS on the server.

    # January 24, 2013 at 11:03 am

    Thanks Ross, I suspected as much.

    So, what do you use for your workflow, in terms of updating the live site? I use Coda so I could obviously just FTP the files up every time, though I’d rather have a quicker/safer way. Subversion?

    # January 24, 2013 at 11:10 am

    Use version control – Git. Chris has some good videos on using Git, if you are on Windows or Mac the new Github for Windows/Mac app makes it even easier.

    # January 24, 2013 at 11:11 am

    There’s nothing wrong with SFTP.

    If you want to *keep track* of those changes (entirely different) I’d recommend using Git.

    # January 24, 2013 at 11:12 am

    I disagree with @notfilc with Github’s app, though, I think it’s terrible. You’re honestly better off using the command line than that thing. If you’re in the market for an app, Tower is awesome (I believe that’s what Chris uses as well).

    # January 24, 2013 at 11:18 am

    Thanks guys. Actually, I do have the Github app. I use it to push changes to a free WordPress theme I host at Github. But I’ve never used it to update a live website. Hmm. I host everything at Eleven2 and it looks like they enable Git. Just not sure how to set it all up…

    # January 24, 2013 at 11:20 am

    I don’t think anyone was recommending that you use it to update a live website.

    # January 24, 2013 at 11:20 am

    (though it is a possibility)

    # January 24, 2013 at 11:41 am

    I don’t like the Github app, altough I tried it only on Windows. I use SmartGit on Windows now as a GUI and I soppose on Mac there are better apps as well, e.g. Tower.

    # January 24, 2013 at 1:47 pm

    So when you guys develop a theme locally and want to push changes live (and track them), do you use Github, or SVN? Do I need certain credentials to set that up with my host? I have found I really really suck at UNIX/Terminal stuff, and would prefer some kind of GUI… :/

    # January 24, 2013 at 1:54 pm

    Personally, I keep pushing to Github and pushing to live as two separate things.

    # January 24, 2013 at 4:15 pm

    I use Coda and FTP as well, and it works fine for me.
    I rarely find myself needing to track changes on my simple blog.

    If you still want to do it (and it is a good idea), I would recommend some of [Chris's screencasts](http://css-tricks.com/video-screencasts/) on Git.

    # January 24, 2013 at 10:07 pm

    If you’re feeling adventurous you can use Git with Capistrano. Capistrano will compile your repo into a tar ball and upload it (I think) via sftp. Capistrano is generally used by Rails developers, but I’ve gotten it to work on a couple PHP sites and I really enjoy it.

    Here’s an article that I wrote that covers a basic deploy script for Capistrano with PHP. < http://baylorrae.com/easy-php-deployments-with-capistrano-with-shared-hosting/>

Viewing 14 posts - 1 through 14 (of 14 total)

You must be logged in to reply to this topic.

*May or may not contain any actual "CSS" or "Tricks".