Skip to content

Commit

Permalink
(#995) Remove documentation about Gitter
Browse files Browse the repository at this point in the history
Since the usage of Gitter is being removed, we should remove mention of
it in the documentation.
  • Loading branch information
gep13 committed May 2, 2024
1 parent 69b8c9b commit 2639bf0
Show file tree
Hide file tree
Showing 7 changed files with 10 additions and 57 deletions.
4 changes: 2 additions & 2 deletions docs/input/assets/css/override.less
Original file line number Diff line number Diff line change
Expand Up @@ -97,9 +97,9 @@ pre:hover .btn-copy {

@font-family-sans-serif: "Roboto", Helvetica, Arial, sans-serif;

/* For Gitter and GitHub */
/* For GitHub */
.bottom-footer {
margin-bottom: 40px !important; // Make room for Gitter and GitHub buttons
margin-bottom: 40px !important; // Make room for GitHub buttons
}

.github-button {
Expand Down
18 changes: 0 additions & 18 deletions docs/input/docs/fundamentals/environment-variables.md
Original file line number Diff line number Diff line change
Expand Up @@ -42,24 +42,6 @@ The Personal Access Token of the GitHub account to be used.
If `GITHUB_PAT` is not set, the alternatives of `GH_TOKEN` and `GITHUB_TOKEN` are considered.
:::

## Gitter

When a successful release build has been completed, Cake.Recipe can be configured to send out a notification (with configurable message) to a Gitter Room. There are two required environment variables that needs to be set to make this happen. Further information about find this information can be found in the Cake.Gitter [documentation](https://cake-contrib.github.io/Cake.Gitter/docs/usage/requiredinformation).

:::{.alert .alert-info}
**NOTE:**

In addition to these environment variables being present, and correct, the control variable [shouldPostToGitter](./set-parameters#shouldPostToGitter) also needs to be set to true. The default value for this parameter is true.
:::

### GITTER_TOKEN

The authentication token for the user who should post to the room.

### GITTER_ROOM_ID

The room ID where you want the message to be sent.

## Slack

When a release build fails, Cake.Recipe can be configured to send out a notification (with configurable message) to a Slack Channel. There are two required environment variables that s to be set to make this happen. Further information about find this information can be found in the Cake.Slack [documentation](https://github.com/cake-contrib/Cake.Slack).
Expand Down
1 change: 0 additions & 1 deletion docs/input/docs/fundamentals/print-parameters.md
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,6 @@ IsTagged: False
BranchType: Develop
TreatWarningsAsErrors: True
ShouldSendEmail: True
ShouldPostToGitter: True
ShouldPostToSlack: True
ShouldPostToTwitter: True
ShouldPostToMicrosoftTeams: False
Expand Down
20 changes: 0 additions & 20 deletions docs/input/docs/fundamentals/set-parameters.md
Original file line number Diff line number Diff line change
Expand Up @@ -177,14 +177,6 @@ Default Value:
Title.Replace(".", "-").ToLower();
```

### shouldPostToGitter

This is used as a final control variable for whether or not notification messages should be posted to Gitter when the a final release build (i.e. a tagged build) completes.

Type: `bool`

Default Value:

```csharp
true
```
Expand Down Expand Up @@ -502,18 +494,6 @@ Default Value:
60
```

### gitterMessage

This is the message that is sent to Gitter at the end of a tagged build. This is formatted with the calculated version number, as well as the Title parameter.

Type: `string`

Default Value:

```csharp
@/all Version {0} of the {1} Addin has just been released, this will be available here https://www.nuget.org/packages/{1}, once package indexing is complete."
```

### microsoftTeamsMessage

This is the message that is sent to Microsoft Teams at the end of a tagged build. This is formatted with the calculated version number, as well as the Title parameter.
Expand Down
20 changes: 6 additions & 14 deletions docs/input/docs/fundamentals/set-variable-names.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,24 +6,24 @@ Description: Override the default names of the environment variables used by Cak

Cake.Recipe is driven by [environment variables](./environment-variables). These are used to store the sensitive information that is required during the build process. For example, the username and password needed to send email, or the token required to access GitHub.

Cake.Recipe has default environment variable names for all the pieces of information that are required. The expectation is that either locally on your own machine, or on the CI/CD pipeline that you are using, you set the values for all of the ones that you intend to use. For example, if you want to send messages to Gitter when the build succeeds, you will need to set environment variables with the names required.
Cake.Recipe has default environment variable names for all the pieces of information that are required. The expectation is that either locally on your own machine, or on the CI/CD pipeline that you are using, you set the values for all of the ones that you intend to use. For example, if you want to send messages to Slack when the build succeeds, you will need to set environment variables with the names required.

However, it may be necessary to change these environment variable names. One example of when this is required is when you might be using Cake.Recipe on two completely separate projects. In this scenario, you might need to set the Gitter Environment variables for both projects, but they may require different values.
However, it may be necessary to change these environment variable names. One example of when this is required is when you might be using Cake.Recipe on two completely separate projects. In this scenario, you might need to set the Slack Environment variables for both projects, but they may require different values.

As an example, lets say that you wanted to change the name of the environment variables that stored the Gitter credential information. You could add something like the following to your [recipe.cake](./recipe-cake) file:
As an example, lets say that you wanted to change the name of the environment variables that stored the Slack credential information. You could add something like the following to your [recipe.cake](./recipe-cake) file:

```csharp
Environment.SetVariableNames(gitterTokenVariable: "PROJECTA_GITTER_TOKEN", gitterRoomIdVariable: "PROJECTA_GITTER_ROOM_ID");
Environment.SetVariableNames(slackTokenVariable: "PROJECTA_SLACK_TOKEN", slackChannelVariable: "PROJECTA_SLACK_CHANNEL");
```

This would mean that when required, Cake.Recipe would check the machine which it is running on for environment variables names `PROJECTA_GITTER_TOKEN` and `PROJECTA_GITTER_ROOM_ID`, rather than the default of `GITTER_TOKEN` and `GITTER_ROOM_ID`.
This would mean that when required, Cake.Recipe would check the machine which it is running on for environment variables names `PROJECTA_SLACK_TOKEN` and `PROJECTA_SLACK_CHANNEL`, rather than the default of `SLACK_TOKEN` and `SLACK_CHANNEL`.

There is another scenario where you might want to override the environment variable names when running locally on your own machine, but you might want to use the default variable names when running on a CI/CD system. To facilitate that, you can do something similar to the following:

```csharp
if (BuildSystem.IsLocalBuild)
{
Environment.SetVariableNames(gitterTokenVariable: "PROJECTA_GITTER_TOKEN", gitterRoomIdVariable: "PROJECTA_GITTER_ROOM_ID");
Environment.SetVariableNames(slackTokenVariable: "PROJECTA_SLACK_TOKEN", slackChannelVariable: "PROJECTA_SLACK_CHANNEL");
}
else
{
Expand All @@ -39,14 +39,6 @@ The `SetVariableNames` method uses the concept of optional parameters, in fact,

Default value: `GITHUB_PAT`

### gitterTokenVariable

Default value: `GITTER_ROOM_ID`

### gitterRoomIdVariable

Default value: `GITTER_ROOM_ID`

### slackTokenVariable

Default value: `SLACK_TOKEN`
Expand Down
2 changes: 1 addition & 1 deletion docs/input/docs/usage/create-pre-release.md
Original file line number Diff line number Diff line change
Expand Up @@ -25,4 +25,4 @@ which are documented [here](creating-release){.alert-link}.
6. Check the generated release notes and make required manual changes.
7. Publish the draft release on GitHub.

The last step will tag the release and trigger another build including the publishing. The build will automatically publish the build artifacts to the GitHub release, publish to NuGet and notify about the new release through Twitter and Gitter ((by default, but it is also possbile to add notifications to [Microsoft Teams](../fundamentals/environment-variables#microsoft-teams) and [email](../fundamentals/environment-variables#email))), based on your specific settings.
The last step will tag the release and trigger another build including the publishing. The build will automatically publish the build artifacts to the GitHub release, publish to NuGet and notify about the new release through Twitter ((by default, but it is also possible to add notifications to [Microsoft Teams](../fundamentals/environment-variables#microsoft-teams) and [email](../fundamentals/environment-variables#email))), based on your specific settings.
2 changes: 1 addition & 1 deletion docs/input/docs/usage/creating-release.md
Original file line number Diff line number Diff line change
Expand Up @@ -23,4 +23,4 @@ Both are not requirements though and you can adopt the steps to other environmen
7. If release is ready finish release (merge back into `master` and `develop`) but don't tag the release yet.
8. Publish the draft release on GitHub.

The last step will tag the release and trigger another build including the publishing. The build will automatically publish the build artifacts to the GitHub release, publish to NuGet and notify about the new release through Twitter and Gitter (by default, but it is also possbile to add notifications to [Microsoft Teams](../fundamentals/environment-variables#microsoft-teams) and [email](../fundamentals/environment-variables#email)), based on your specific settings.
The last step will tag the release and trigger another build including the publishing. The build will automatically publish the build artifacts to the GitHub release, publish to NuGet and notify about the new release through Twitter (by default, but it is also possible to add notifications to [Microsoft Teams](../fundamentals/environment-variables#microsoft-teams) and [email](../fundamentals/environment-variables#email)), based on your specific settings.

0 comments on commit 2639bf0

Please sign in to comment.