Git Product home page Git Product logo

Comments (8)

popcornmix avatar popcornmix commented on August 16, 2024

It seems to be doing the right think on my Ubuntu build machine.
Are you seeing the '\n' characters in version.h?
What platform are you building it on?

$ cat version.h
#ifndef __VERSION_H__
#define __VERSION_H__

#define VERSION_DATE "Mon, 29 Jul 2013 12:40:17 +0100"
#define VERSION_HASH "efd1049"
#define VERSION_BRANCH "master"
#define VERSION_REPO "[email protected]:popcornmix/omxplayer.git"

#endif

@skgsergio - any comments?

from omxplayer.

Huulivoide avatar Huulivoide commented on August 16, 2024

Yeah the '\n's are echoed to version.h as they are.

I'm using Arch. Ubuntu must have an alias set up by default for
echo -e....

from omxplayer.

Huulivoide avatar Huulivoide commented on August 16, 2024

It seems that Ubuntu's default shell Dash doesn't
support -e, but instead does it by default.
One way to fox this is to use full path to the
echo implementation provided by coreutils
/bin/echo or printf command (same syntax as in c)

from omxplayer.

fastcat avatar fastcat commented on August 16, 2024

Or use #!/bin/bash in scripts that use bashisms...

from omxplayer.

skgsergio avatar skgsergio commented on August 16, 2024

I were traveling so I'm sorry I didn't reply sooner.

My script its working on Debian (and dereivated) because uses dash.
I'll convert it to bash as is more "standard" (I use ZSH :P) and I'll make a pull request.

from omxplayer.

popcornmix avatar popcornmix commented on August 16, 2024

I wonder if this is a more portable way of producing a blank line.

echo #define VERSION_H
echo

from omxplayer.

fastcat avatar fastcat commented on August 16, 2024

Devil's advocate question: is there any need for blank lines in a generated header file like that? There's so little to the generated file, lack of blank lines arguably won't even hurt readability.

from omxplayer.

skgsergio avatar skgsergio commented on August 16, 2024

There is no reason except me, anyway I've noticed things like ${ref#refs/heads/} or ${upstream%/$branch} are behave strange in non bash interpreters.

from omxplayer.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.