I often need to wait until Github CI is done.
I see "N in progress":
After the is done I need to do additional steps like merging the PR and incorporate the change in other tools.
I tried guessing how long the job takes, but the duration differs a lot because the job runners are sometimes used by other jobs.
How to get a notified as soon as the CI job is done?
I use Ubuntu Linux.
I often need to wait until Github CI is done.
I see "N in progress":
After the is done I need to do additional steps like merging the PR and incorporate the change in other tools.
I tried guessing how long the job takes, but the duration differs a lot because the job runners are sometimes used by other jobs.
How to get a notified as soon as the CI job is done?
I use Ubuntu Linux.
Share Improve this question asked Feb 14 at 6:52 guettliguettli 28k105 gold badges410 silver badges753 bronze badges2 Answers
Reset to default 0if we run some local service on PORT
, which is handling playSound
functionality while making POST request, then using this step we might achive sound functionality
add this step at the end of .xml
, which would make POST
request on PORT
-name: Send Notification to Ubuntu
run: curl -X POST http://YOUR_UBUNTU_IP:PORT
here is example of app.js doing sem
const express = require("express");
const player = require("play-sound")({});
const app = express();
const PORT = 3000;
app.use(express.json());
app.get("/",(req,res)=>{
res.json("Hello ")
})
app.post("/play-sound", (req, res) => {
console.log("Received a POST request, playing sound...");
player.play("playsound.mp3", (err) => {
if (err) {
console.error("Error playing sound:", err);
return res.status(500).json({ message: "Failed to play sound" });
}
res.json({ message: "Sound played successfully!" });
});
});
app.listen(PORT, () => {
console.log(`Server is running on http://localhost:${PORT}`);
});
directory structure
-node_modules
-app.js
-playsound.mp3
-package.json
..other
I found that solution:
gh run watch; music
gh run watch
gives you a list of jobs, you can select one. When it is finished, the next command is called music. Use whatever command you want for that. For me music
is a small script which plays a song I like.