Showing posts from January, 2021

A chessboard

In this version of chess, only two kings pieces are placed on the chessboard. Initially, the coordinates of the first king piece are generated   ( X 1 ,   Y 1 ) , it is placed on the chessboard at the generated position. Now, the coordinates of the second king piece are generated   ( X 2 ,   Y 2 ) , it is placed on the chessboard at the generated position. These pieces can be moved in a sequential manner, that is, one by one, starting from the first piece. Both the kings want to win if they can not, at least draw. Rules The chessboard is a standard   8 × 8   board. The kings can move from one cell to another if they have an edge or corner in common. If the generated coordinates of the second king are exactly equal to the first, then the second king wins. Both players play optimally. The game is considered to be won by the first king piece if after it moves, then it can have the same coordinates as the second. The second king piece becomes the winner if after this piece is moved, then b

How to pass parameters in webhook?

Hey everyone 😊, Today I want to share another interesting thing which I found in StackOverflow and that is how to pass parameters in webhook. Those who don't know about webhook I advise you to google about it before going further reading.  So for demonstration purpose, I am going to use Jenkins and Generic Webhook plugin . I created a job and called it testing  and select Generic Webhook  Trigger . Thereafter I add Request Parameter   and in the request parameter I added the name of the request which is name Thereafter I added a token to specify that this job can only be triggered. After this, I select Execute Shell from Build  and write the following code  After doing this add webhook URL in bitbucket repository or  GitHub repository with the parameter. The URL is look something like this  Webhook URL:- https://[YOUR_JENKINS_URL]/generic-webhook-trigger/invoke?token=trigger&name=Svastikkka  The configuration will something like this After saving my webhook configuration I

Popular posts from this blog

How to pass parameters in webhook?

Access and modify all the resources of our Wiki.js using WikiJS API

Fahrenheit to Celsius