Skip to content

Commit

Permalink
Add info about installing FPC to the README
Browse files Browse the repository at this point in the history
  • Loading branch information
suve committed Oct 14, 2021
1 parent 2760d65 commit 60932b0
Show file tree
Hide file tree
Showing 2 changed files with 41 additions and 4 deletions.
43 changes: 40 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
# GHAction for the Free Pascal Compiler

This GitHub Action allows you to compile Pascal programs using the Free Pascal Compiler.
It will parse the compiler's diagnostics and create annotations on your commits and pull requests.

## Inputs

Expand All @@ -15,9 +16,9 @@ This GitHub Action allows you to compile Pascal programs using the Free Pascal C

### fail-on

The `fail-on` input can be used to control when the action should fail.
By default, the action will fail only if an error occurs (or if the compiler crashes).
If you want to be more strict with your code, you can use this option to have the action
The `fail-on` input can be used to control when the Action should fail.
By default, the Action will fail only if an error occurs (or if the compiler crashes).
If you want to be more strict with your code, you can use this option to have the Action
mark itself as "failed" when any warnings occur.

With a C compiler, you could use the `-Werror` compiler option to have the compiler treat any
Expand Down Expand Up @@ -57,3 +58,39 @@ Implementation-wise, the flags passed to the Free Pascal compiler are `-v0 -viXX
where `XXX` is the value for this input.
As such, if you want to set the verbosity level through the `flags` input,
you **need** to set this input to an empty string - this disables adding the two `-v` flags.

## Getting FPC

This Action assumes that FPC is already installed in your build environment; it does not handle
installing it for you. You can do that yourself by adding one of the following steps
to your GHActions workflow.

### Ubuntu

```
- name: Install FPC
run: |
export DEBIAN_FRONTEND=noninteractive
sudo apt-get update
sudo apt-get install -y fpc
```

### MacOS

```
- name: Install FPC
run: |
brew update
brew install fpc
```

### MS Windows

As of the time of writing, Chocolatey does not have a separate package for FPC,
so you'll have to install Lazarus instead (it comes with a bundled copy of the compiler).

```
- name: Install Lazarus
run: |
choco install lazarus
```
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "GHActions-FPC",
"description": "GitHub action for running the Free Pascal Compiler",
"version": "0.1.0",
"version": "0.2.0",
"license": "Zlib",
"author": "suve",
"repository": "https://github.com/suve/GHActions-FPC",
Expand Down

0 comments on commit 60932b0

Please sign in to comment.