Live data from Hacker News

GitHub Actions is my new favorite free programming tool [video]

bytesized.xyz

31–40 of 134 posts

Re: GitHub Actions is my new favorite free programming tool [video]

#31
post #13

I have spent the last two days fighting with these new Github tools. I've been trying to do a simple Hello-World Maven app, built on Github Actions and deployed to Github Packages. It does not work. Github documentation is a disaster. They leave out critical parts. They don't provide examples. Everything they write is terse, confusing, and incomplete. They have short little articles on how to do things, and for each…

It's kind of ugly, but I spend a bit of time using some node scripts to orchestrate a scheduled "nightly" build of an application package that does some relatively funky stuff. See the .github/workflows and scripts/ areas... again, it's hacky. Was trying to do something that wasn't very well documented by example strictly speaking.

You can probably use another scripting language to use the github interface.

https://github.com/bbs-io/syncterm-windows

Aside, you need to pass your github token in as part of your workflow config.

https://github.com/bbs-io/syncterm-windows/blob/master/.gith...

Re: GitHub Actions is my new favorite free programming tool [video]

#32

Github actions is nice but I think they go to wrong direction. The way they work is you are given an image then you have to use a thing call Github action, which basically just to extract out into YAML to define a certain steps for install any dependencies, execute shell script ... I don't know why they didn't allow us to use any docker image we want so we don't have to waste time to use actions to install dependenci…

My approach to this was to create generic images. For example there are various actions out there to "Run `make test`", "Run pytest", or "Run go tests". Why be specific? Why not include a shell-script in your repository, and allow that to run the tests? That way you just need one "Run test-script" action: https://github.com/skx/github-action-tester

I've done pretty much just this... choosing the appropriate OS image(s) and relying on a given scripting language in the environment.. the scripts themselves are in code and the YAML us just enough to run what's needed.

https://github.com/bbs-io/syncterm-windows/blob/master/.gith...

Re: GitHub Actions is my new favorite free programming tool [video]

#33

Github actions is nice but I think they go to wrong direction. The way they work is you are given an image then you have to use a thing call Github action, which basically just to extract out into YAML to define a certain steps for install any dependencies, execute shell script ... I don't know why they didn't allow us to use any docker image we want so we don't have to waste time to use actions to install dependenci…

We use Buddy: https://buddy.works/

Each step of a pipeline is just a docker container of your choice and running whatever commands you want with a persistent workspace volume throughout the pipeline.

There's a few others that work this way like Semaphore, Drone CI, GoCD, CircleCI, Azure Devops but none are as fast, seamless and easy as Buddy.

Re: GitHub Actions is my new favorite free programming tool [video]

#34

Github actions is nice but I think they go to wrong direction. The way they work is you are given an image then you have to use a thing call Github action, which basically just to extract out into YAML to define a certain steps for install any dependencies, execute shell script ... I don't know why they didn't allow us to use any docker image we want so we don't have to waste time to use actions to install dependenci…

I'm not sure if this is the 'right way' or not, but for a recent Go project, I just scripted the build via

    - name: build
      run: |
        docker run --rm -v \
          "$PWD":/usr/src/my-project \
          -w /usr/src/my-project \
          -e GOOS -e GOARCH \
          golang:1.13 go build -v -o my-project-$GOOS-$GOARCH
      env:
        GOOS: ${{ matrix.os }}
        GOARCH: ${{ matrix.arch }}

(GitHub Actions's build environment already has Docker installed/configured, so there's no setup necessary for "run: docker run" to work.)

I did this explicitly because I didn't want to use that "setup-go" action you linked, which at the time (I haven't doubled checked it recently) didn't support Go 1.13. Far better to me to use the Docker image, which has explicit instructions even for cross-platform compilation in its README, than rely on some weird action setup, in my opinion.

Re: GitHub Actions is my new favorite free programming tool [video]

#35

Earlier quoted context omitted.

I am with you on this. It seems to be a new trend: “show users how to do a hello world” which was disregarded in the past... but somehow that turned into “instead of providing real documentation” rather than “in addition to.” It’s not just GitHub. There’s a language I (and the rest of HN) love that has adopted “story format” for documentation but is missing real, hard technical documentation apart from method-level c…

Someone please tell the Google Cloud Platform teams this. So many hello world examples which reek of, "I was told to write documentation but I really hate writing documentation". I mean this in good faith, I think writing documentation for a product you don't actually use is a miserable experience and I hope they can find a better balance... Writing documentation also seems to be a task you kick out to your junior de…

Oh god yes, so frustrating

Re: GitHub Actions is my new favorite free programming tool [video]

#36
post #13

I have spent the last two days fighting with these new Github tools. I've been trying to do a simple Hello-World Maven app, built on Github Actions and deployed to Github Packages. It does not work. Github documentation is a disaster. They leave out critical parts. They don't provide examples. Everything they write is terse, confusing, and incomplete. They have short little articles on how to do things, and for each…

I am with you on this. It seems to be a new trend: “show users how to do a hello world” which was disregarded in the past... but somehow that turned into “instead of providing real documentation” rather than “in addition to.” It’s not just GitHub. There’s a language I (and the rest of HN) love that has adopted “story format” for documentation but is missing real, hard technical documentation apart from method-level c…

I assume you’re talking about Go here?

Re: GitHub Actions is my new favorite free programming tool [video]

#37
post #13

I have spent the last two days fighting with these new Github tools. I've been trying to do a simple Hello-World Maven app, built on Github Actions and deployed to Github Packages. It does not work. Github documentation is a disaster. They leave out critical parts. They don't provide examples. Everything they write is terse, confusing, and incomplete. They have short little articles on how to do things, and for each…

I am with you on this. It seems to be a new trend: “show users how to do a hello world” which was disregarded in the past... but somehow that turned into “instead of providing real documentation” rather than “in addition to.” It’s not just GitHub. There’s a language I (and the rest of HN) love that has adopted “story format” for documentation but is missing real, hard technical documentation apart from method-level c…

I read an article[0] on HN[1] recently — it talks about the different types of documentation. To quote it directly:

"Documentation needs to include and be structured around its four different functions: tutorials, how-to guides, explanation and technical reference. Each of them requires a distinct mode of writing. People working with software need these four different kinds of documentation at different times, in different circumstances - so software usually needs them all."

I agreed with its premise — I've found things that only have "story format" docs (i.e. explanation / how-to guides) to be really frustrating. On the other hand, if all that's available is a deep and highly particular technical reference, it's really difficult to get started sometimes.

[0] https://www.divio.com/blog/documentation/

[1] https://news.ycombinator.com/item?id=21289832

Re: GitHub Actions is my new favorite free programming tool [video]

#38
post #34

Github actions is nice but I think they go to wrong direction. The way they work is you are given an image then you have to use a thing call Github action, which basically just to extract out into YAML to define a certain steps for install any dependencies, execute shell script ... I don't know why they didn't allow us to use any docker image we want so we don't have to waste time to use actions to install dependenci…

I'm not sure if this is the 'right way' or not, but for a recent Go project, I just scripted the build via - name: build run: | docker run --rm -v \ "$PWD":/usr/src/my-project \ -w /usr/src/my-project \ -e GOOS -e GOARCH \ golang:1.13 go build -v -o my-project-$GOOS-$GOARCH env: GOOS: ${{ matrix.os }} GOARCH: ${{ matrix.arch }} (GitHub Actions's build environment already has Docker installed/configured, so there's no…

I like this approach as well, though I typically include a `Dockerfile` in my Go projects so my run task is just:

    - name: Build
      run: docker build -t me/image:latest .
      env:
        DOCKER_BUILDKIT: 1
        GOOS: ${{ matrix.os }}
        GOARCH: ${{ matrix.arch }}

Re: GitHub Actions is my new favorite free programming tool [video]

#39
I'd be hesitant to build on GitHub tools that have overlap with anything Microsoft provides. When something similar is introduced to Azure, why keep the subsidiary's internal competition around?

This happened already with VS Code vs. Github's Atom editor whose development has ceased earlier this year. (Not that I ever was a huge fan of Atom, but its discontinuation is a direct result of the Microsoft acquisition.)

Re: GitHub Actions is my new favorite free programming tool [video]

#40

Github actions is nice but I think they go to wrong direction. The way they work is you are given an image then you have to use a thing call Github action, which basically just to extract out into YAML to define a certain steps for install any dependencies, execute shell script ... I don't know why they didn't allow us to use any docker image we want so we don't have to waste time to use actions to install dependenci…

You can use an arbitrary container: https://github.com/judge2020/test-actions2/blob/master/.gith... - https://github.com/judge2020/test-actions2/commit/5732cd3496... although I admit it's slower than CircleCI's runners.
Post reply on HN