Skip to content

Commit

Permalink
Merge pull request #72 from ba-st/pharo-10
Browse files Browse the repository at this point in the history
Add Pharo 10 to build matrix
  • Loading branch information
gcotelli authored Apr 5, 2022
2 parents c088d73 + 74e20ad commit c4c8059
Show file tree
Hide file tree
Showing 22 changed files with 154 additions and 113 deletions.
2 changes: 2 additions & 0 deletions .gitattributes
Original file line number Diff line number Diff line change
@@ -1 +1,3 @@
*.st linguist-language=Smalltalk
*.st eol=lf
*.st text diff
4 changes: 2 additions & 2 deletions .github/workflows/loading-groups.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
name: Group loading check
name: Baseline groups

on: [push,pull_request,workflow_dispatch]

Expand All @@ -8,7 +8,7 @@ jobs:
strategy:
fail-fast: false
matrix:
smalltalk: [ Pharo64-9.0, Pharo64-8.0 ]
smalltalk: [ Pharo64-10, Pharo64-9.0, Pharo64-8.0 ]
load-spec: [ deployment, dependent-sunit-extensions, tests, tools, development ]
name: ${{ matrix.smalltalk }} + ${{ matrix.load-spec }}
steps:
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/unit-tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ jobs:
runs-on: ubuntu-latest
strategy:
matrix:
smalltalk: [ Pharo64-9.0, Pharo64-8.0, Pharo64-7.0, Pharo32-7.0 ]
smalltalk: [ Pharo64-10, Pharo64-9.0, Pharo64-8.0, Pharo64-7.0, Pharo32-7.0 ]
name: ${{ matrix.smalltalk }}
steps:
- uses: actions/checkout@v2
Expand Down
20 changes: 7 additions & 13 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -22,19 +22,13 @@ You can report issues [here](https://github.com/ba-st/Buoy/issues/new)
- Code contributions without test cases have a lower probability of being merged
into the main branch.

### Using Iceberg

1. Download a [Pharo Image and VM](https://get.pharo.org/64)
2. Clone the project or your fork using Iceberg
3. Open the Working Copy and using the contextual menu select
`Metacello -> Install baseline...`
4. Input `Development`
5. This will load the base code and the test cases
6. Create a new branch to host your code changes
7. Do the changes
8. Run the test cases
9. Commit and push your changes to the branch using the Iceberg UI
10. Create a Pull Request against the `release-candidate` branch
1. [Load the project code in a Pharo image](docs/how-to/how-to-load-in-pharo.md)
2. Create a new branch to host your code changes
3. Do the changes
4. Run the test cases
5. Commit and push your changes to the branch using the Iceberg UI. You may need
to add your fork if lacking the required permissions to push to the main repo.
6. Create a Pull Request against the `release-candidate` branch

## Contributing documentation

Expand Down
2 changes: 1 addition & 1 deletion LICENSE
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
MIT License

Copyright (c) 2017-2021 Gabriel Cotelli, Maximiliano Tabacman and Buenos Aires Smalltalk Contributors
Copyright (c) 2017-2022 Gabriel Cotelli, Maximiliano Tabacman and Buenos Aires Smalltalk Contributors

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
Expand Down
55 changes: 13 additions & 42 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,59 +6,31 @@ This project aims to complement [Pharo](https://www.pharo.org) adding useful ext

[![Unit Tests](https://github.com/ba-st/Buoy/actions/workflows/unit-tests.yml/badge.svg)](https://github.com/ba-st/Buoy/actions/workflows/unit-tests.yml)
[![Coverage Status](https://codecov.io/github/ba-st/Buoy/coverage.svg?branch=release-candidate)](https://codecov.io/gh/ba-st/Buoy/branch/release-candidate)
[![Group loading check](https://github.com/ba-st/Buoy/actions/workflows/loading-groups.yml/badge.svg)](https://github.com/ba-st/Buoy/actions/workflows/loading-groups.yml)
[![Baseline Groups](https://github.com/ba-st/Buoy/actions/workflows/loading-groups.yml/badge.svg)](https://github.com/ba-st/Buoy/actions/workflows/loading-groups.yml)
[![Markdown Lint](https://github.com/ba-st/Buoy/actions/workflows/markdown-lint.yml/badge.svg)](https://github.com/ba-st/Buoy/actions/workflows/markdown-lint.yml)

[![GitHub release](https://img.shields.io/github/release/ba-st/Buoy.svg)](https://github.com/ba-st/Buoy/releases/latest)
[![Pharo 7.0](https://img.shields.io/badge/Pharo-7.0-informational)](https://pharo.org)
[![Pharo 8.0](https://img.shields.io/badge/Pharo-8.0-informational)](https://pharo.org)
[![Pharo 9.0](https://img.shields.io/badge/Pharo-9.0-informational)](https://pharo.org)
[![Pharo 10](https://img.shields.io/badge/Pharo-10-informational)](https://pharo.org)

Quick links

- [**Explore the docs**](docs/)
- [**Explore the docs**](docs/README.md)
- [Report a defect](https://github.com/ba-st/Buoy/issues/new?labels=Type%3A+Defect)
- [Request a feature](https://github.com/ba-st/Buoy/issues/new?labels=Type%3A+Feature)

## Feature List
## Features and Extensions

### Assertions

This library is aimed at providing a simpler way to enforce and check assertions.
The main focus point is to use it in the business model. Read the [online tutorial](docs/Assertions.md).

### Collections

This library provides additional abstractions for Collections. See the [related documentation.](docs/Collections.md)

### Comparison

This library provides support to compare objects both for equality and identity.
They are typically used to implement the `=` and `hash` methods. See the
[related documentation.](docs/Comparison.md)

### Math

This library provides basic arithmetic abstractions like Percentages. See the
[related documentation.](docs/Math.md)

### Bindings and Optionals

This library provides support to express optional values and required values,
that can be unknown at the beginning of an execution. See the [related documentation.](docs/BindingsAndOptionals.md)

### Exception Handling

Provides extensions to the [exception handling mechanics](docs/ExceptionHandling.md).

### Metaprogramming

This library provides some abstractions like [namespaces](docs/Namespaces.md)
and [interfaces](docs/Interfaces.md).

### SUnit

Provides [extensions to the SUnit framework](docs/SUnit.md).
- Assertions library
- Additional collections and extensions
- Comparison affordances
- Additional Math abstractions
- Bindings and Optionals
- Exception Handling extensions
- Metaprogramming
- SUnit extensions

## License

Expand All @@ -67,8 +39,7 @@ Provides [extensions to the SUnit framework](docs/SUnit.md).

## Installation

To load the project in a Pharo image, or declare it as a dependency of your own
project follow this [instructions](docs/Installation.md).
To load the project in a Pharo image follow this [instructions](docs/how-to/how-to-load-in-pharo.md).

## Contributing

Expand Down
53 changes: 0 additions & 53 deletions docs/Installation.md

This file was deleted.

29 changes: 29 additions & 0 deletions docs/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
# Buoy Documentation

Buoy aims to complement [Pharo](https://www.pharo.org) adding useful extensions.

To learn about the project, [install it](how-to/how-to-load-in-pharo.md) and
[follow the assertions tutorial](tutorial/Assertions.md), or expand your
understanding over specific topics:

- **Collections**: Additional abstractions for Collections.
See the [related documentation.](reference/Collections.md)
- **Comparison**: Support to compare objects both for equality and identity.
They are typically used to implement the `=` and `hash` methods. See the
[related documentation.](reference/Comparison.md)
- **Math**: Basic arithmetic abstractions like Percentages. See the
[related documentation.](reference/Math.md)
- **Bindings and Optionals**: Support to express optional values and
required values, that can be unknown at the beginning of an execution.
See the [related documentation.](reference/BindingsAndOptionals.md)
- **Exception Handling**: Extensions to the [exception handling mechanics](reference/ExceptionHandling.md).
- **Metaprogramming**: Some abstractions like [namespaces](reference/Namespaces.md)
and [interfaces](reference/Interfaces.md).
- **SUnit**: [Extensions to the SUnit framework](reference/SUnit.md).

---

To use the project as a dependency of your project, take a look at:

- [How to use Stargate as a dependency](how-to/how-to-use-as-dependency-in-pharo.md)
- [Baseline groups reference](reference/Baseline-groups.md)
35 changes: 35 additions & 0 deletions docs/how-to/how-to-load-in-pharo.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
# How to load Buoy in a Pharo image

## Using Metacello

1. Download a [Pharo VM and image](https://pharo.org/download)
2. Open your Pharo image
3. Open a Playground
4. Evaluate:

```smalltalk
Metacello new
baseline: 'Buoy';
repository: 'github://ba-st/Buoy:release-candidate';
load: 'Development'.
```

> Change `release-candidate` to some released version if you want a pinned version
## Using Iceberg

1. Download [pharo VM and image](https://pharo.org/download)
2. Open your Pharo image
3. Open Iceberg
4. Click the *Add* repository button
5. Select *Clone from github.com* and enter `ba-st` as owner name and `Buoy`
as project name
6. Click *Ok*
7. Select the repository in the main Iceberg window
8. Open the contextual menu and select
*Metacello -> Install baseline of Buoy ...*
9. Type `Development` and click *Ok*

> After Iceberg cloned a repository, it will be checked-out at the default
> branch (in this case `release-candidate`). If you want to work on a different
> branch or commit, perform the checkout before the baseline installation step.
42 changes: 42 additions & 0 deletions docs/how-to/how-to-use-as-dependency-in-pharo.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,42 @@
# How to use Buoy as dependency in a Pharo product

In order to include **Buoy** as part of your project, you should reference
the package in your product baseline:

1. Define the Buoy repository and version to be used, and the [baseline groups](../reference/Baseline-groups.md)
you want to depend on (usually it will be `Deployment`).

If you're unsure on what to depend use the *Dependency Analyzer*
tool to choose an appropriate group including the packages you need.

2. Create a method like this one in the baseline class of your product:

```smalltalk
setUpDependencies: spec
spec
baseline: 'Buoy'
with: [ spec repository: 'github://github://ba-st/Buoy:v{XX}' ];
project: 'Buoy-Deployment'
copyFrom: 'Buoy' with: [ spec loads: 'Deployment' ]
```

This will create `Buoy-Deployment` as a valid target that can be used
as requirement in your own packages.

> Replace `{XX}` with the version you want to depend on
3. Use the new loading target as a requirement on your packages. For example:

```smalltalk
baseline: spec
<baseline>
spec
for: #pharo
do: [
self setUpDependencies: spec.
spec
package: 'My-Package'
with: [ spec requires: #('Buoy-Deployment') ] ]
```
13 changes: 13 additions & 0 deletions docs/reference/Baseline-groups.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
# Baseline Groups

Buoy includes the following groups in its Baseline that can be used as
loading targets:

- `Deployment` will load all the packages needed in a deployed application
- `Tests` will load the test cases
- `Tools` will load tooling extensions
- `Dependent-SUnit-Extensions` will load extensions to SUnit
- `CI` is the group loaded in the continuous integration setup, in this
particular case it is the same as `Tests`
- `Development` will load all the needed packages to develop and contribute to
the project
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
10 changes: 9 additions & 1 deletion source/Buoy-Development-Tools/Namespace.extension.st
Original file line number Diff line number Diff line change
Expand Up @@ -7,9 +7,17 @@ Namespace >> gtInspectorItemsIn: composite [
^ bindings gtInspectorItemsIn: composite
]

{ #category : #'*Buoy-Development-Tools' }
Namespace >> inspectionItems: builder [

<inspectorPresentationOrder: 0 title: 'Items'>
^ bindings inspectionItems: builder
]

{ #category : #'*Buoy-Development-Tools' }
Namespace >> spotterForKeysFor: aStep [
<spotterOrder: 15>

<spotterOrder: 15>
<stSpotterOrder: 15>
^ bindings spotterForKeysFor: aStep
]

0 comments on commit c4c8059

Please sign in to comment.