Skip to content

Migrate CI to GitHub Actions #5

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 7 commits into from
Feb 21, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
25 changes: 25 additions & 0 deletions .github/workflows/notify.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
name: Notify about failed build

on:
workflow_run:
workflows: ["Tests"]
types: [completed]

jobs:
notify:
name: 📣 Notify community on failure
if: ${{ github.event_name == 'schedule' && github.event.workflow_run.conclusion == 'failure' }}
runs-on: ubuntu-latest
steps:
- name: Send email on failure
if: ${{ github.event_name == 'schedule' && github.event.workflow_run.conclusion == 'failure' }}
uses: dawidd6/action-send-mail@v2
with:
server_address: ${{ secrets.SMTP_SERVER }}
server_port: ${{ secrets.SMTP_PORT }}
username: ${{ secrets.SMTP_USERNAME }}
password: ${{ secrets.SMTP_PASSWORD }}
subject: GitHub Actions failed for ${{ github.repository }}
body: Build job of ${{ github.repository }} failed! See https://github.com/${{ github.repository }}/actions/runs/${{ github.run_id }} for more information.
to: ${{ secrets.MAIL_RECEIVER }}
Comment on lines +18 to +24
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

If we do want this, someone who has admin access to this repository will need to enter these secrets. The workflow definition is copied pretty much 1:1 from another repository, so I don't expect hard-to-debug failures. I have already some working credentials available, please contact me privately and I'll send them to you. :D

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

To which addresses would you like to send this? I guess most of the folks on squeak-dev are not interested in FileSystem. And neither is Pharo in this different version of the library.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

My first guess would have been squeak-dev since this repository is part of @squeak-smalltalk. Alternatively, I can also add me and you and some other interested people ...

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The ston, tonel, and filesystem repositories are a bit odd in this organization. They are effectively not as supported as, say, the Trunk of Squeak is. I do not believe that either of the three would be undisputedly considered to be part of Squeak, as opposed to what is in Trunk.

from: GitHub Actions
33 changes: 33 additions & 0 deletions .github/workflows/tests.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
name: Tests

on:
push:
schedule:
- cron: '42 2 * * 1' # once a week
workflow_dispatch:

jobs:
test:
strategy:
matrix:
os:
- ubuntu-latest
- macos-latest
- windows-latest
smalltalk:
- Squeak64-trunk
- Squeak64-5.3
- Squeak64-5.2
name: ${{ matrix.smalltalk }} on ${{ matrix.os }}
runs-on: ${{ matrix.os }}
steps:
- uses: actions/checkout@v2
- id: smalltalkci
uses: hpi-swa/setup-smalltalkCI@v1
with:
smalltalk-image: ${{ matrix.smalltalk }}
- run: smalltalkci -s ${{ steps.smalltalkci.outputs.smalltalk-image }}
timeout-minutes: 15
env:
# for uploading coverage reports
GITHUB_TOKEN: ${{ github.token }}
3 changes: 3 additions & 0 deletions .project
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
{
'srcDirectory' : 'src'
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

What does this file belong to and why is it introduced now?

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The commit message could have elaborated on the purpose of this.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Sorry for confusion. This file explains the default directory of the package directory to the newest Metacello version so you do not need to specify the path manually in the load script.

}
25 changes: 16 additions & 9 deletions .smalltalk.ston
Original file line number Diff line number Diff line change
@@ -1,11 +1,18 @@
SmalltalkCISpec {
#loading : [
SCIMetacelloLoadSpec {
#baseline : 'FileSystem',
#directory : 'src',
#load : [ 'tests' ],
#platforms : [ #squeak ],
#useLatestMetacello : true
}
]
#loading : [
SCIMetacelloLoadSpec {
#baseline : 'FileSystem',
#directory : 'src',
#load : [ 'tests' ],
#platforms : [ #squeak ],
#useLatestMetacello : true
}
],
#testing : {
#packages : [ 'FS-Tests-*' ],
#coverage : {
#packages : [ 'FS-AnsiStreams', 'FS-Core', 'FS-Disk', 'FS-FileDirectory-Adapters', 'FS-Memory' ],
#format : #coveralls
}
}
}
10 changes: 0 additions & 10 deletions .travis.yml

This file was deleted.

18 changes: 12 additions & 6 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,8 @@
# FileSystem [![Build Status][travis_badge]][travis]
# FileSystem

[![Build Status][gha_badge]][gha_jobs]
[![Test coverage][coveralls_badge]][coveralls]

FileSystem is a Smalltalk API for accessing files and directories. This is an implementation for Squeak/Smalltalk.

The FileSystem API was proposed as an alternative to the FileDirectory API for file system access in Squeak. It was first implemented as a library package for Squeak. Later it was adopted by Pharo as the main file system access library, while Squeak stayed with FileDirectory.
Expand All @@ -16,10 +20,12 @@ Then, use the following snippet to load:

```smalltalk
Metacello new
baseline: 'FileSystem';
repository: 'github://squeak-smalltalk/squeak-filesystem:master/src';
load.
baseline: 'FileSystem';
repository: 'github://squeak-smalltalk/squeak-filesystem:master/src';
load.
```

[travis]: https://travis-ci.org/j4yk/Squeak-FileSystem
[travis_badge]: https://travis-ci.org/j4yk/Squeak-FileSystem.svg?branch=master
[gha_jobs]: https://github.com/squeak-smalltalk/Squeak-FileSystem/actions/workflows/tests.yml
[gha_badge]: https://github.com/squeak-smalltalk/Squeak-FileSystem/actions/workflows/tests.yml/badge.svg
[coveralls_badge]: https://coveralls.io/repos/github/squeak-smalltalk/Squeak-FileSystem/badge.svg
[coveralls]: https://coveralls.io/github/squeak-smalltalk/Squeak-FileSystem
25 changes: 0 additions & 25 deletions appveyor.yml

This file was deleted.