Skip to content

Commit 6fae2fd

Browse files
authored
Merge pull request #2 from ba-st-dependencies/upstream
Pharo 8 improvements
2 parents 2d981c3 + ef4c084 commit 6fae2fd

File tree

5 files changed

+56
-3
lines changed

5 files changed

+56
-3
lines changed

.gitattributes

+1
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
*.st linguist-language=Smalltalk

.github/workflows/build.yml

+26
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,26 @@
1+
name: Build
2+
3+
on:
4+
pull_request:
5+
push:
6+
7+
jobs:
8+
build:
9+
runs-on: ubuntu-latest
10+
strategy:
11+
matrix:
12+
smalltalk: [ Pharo64-8.0, Pharo64-7.0, Pharo32-7.0 ]
13+
name: ${{ matrix.smalltalk }}
14+
steps:
15+
- uses: actions/checkout@v2
16+
- uses: hpi-swa/setup-smalltalkCI@v1
17+
with:
18+
smalltalk-version: ${{ matrix.smalltalk }}
19+
- run: smalltalkci -s ${{ matrix.smalltalk }}
20+
timeout-minutes: 15
21+
- run: echo "::set-env name=SCI_COVERAGE_FILE_LOCATION::${HOME}/.smalltalkCI/_builds/coveralls_results.json"
22+
- name: Upload coverage to Codecov
23+
uses: codecov/[email protected]
24+
with:
25+
token: ${{ secrets.CODECOV_TOKEN }}
26+
file: ${{ env.SCI_COVERAGE_FILE_LOCATION }}

.project

+3
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
{
2+
'srcDirectory' : ''
3+
}

.smalltalk.ston

+17
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
SmalltalkCISpec {
2+
#loading : [
3+
SCIMetacelloLoadSpec {
4+
#baseline : 'ObjectPool',
5+
#directory : '',
6+
#load : [ 'Tests' ],
7+
#platforms : [ #pharo ]
8+
}
9+
],
10+
#testing : {
11+
#coverage : {
12+
#packages : [ 'ObjectPool*' ],
13+
#service: #codecov,
14+
#auto_upload: false
15+
}
16+
}
17+
}

README.md

+9-3
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,11 @@
11
# ObjectPool
2+
3+
[![GitHub release](https://img.shields.io/github/release/pharo-ide/ObjectPool.svg)](https://github.com/pharo-ide/ObjectPool/releases/latest)
4+
[![Build Status](https://github.com/pharo-ide/ObjectPool/workflows/Build/badge.svg?branch=master)](https://github.com/pharo-ide/ObjectPool/actions?query=workflow%3ABuild)
5+
[![Coverage Status](https://codecov.io/github/pharo-ide/ObjectPool/coverage.svg?branch=master)](https://codecov.io/gh/pharo-ide/ObjectPool/branch/master)
6+
[![Pharo 7.0](https://img.shields.io/badge/Pharo-7.0-informational)](https://pharo.org)
7+
[![Pharo 8.0](https://img.shields.io/badge/Pharo-8.0-informational)](https://pharo.org)
8+
29
Object Pool offers easy way to build pools for objects. One common situation
310
could be pooling database connections. This library was created for supporting pooling
411
of GlorpDBX database connections. However GlorpDBX related code is different
@@ -19,11 +26,11 @@ OPBasicPool new
1926
To get new collection from the pool:
2027
```Smalltalk
2128
pool withPooled: [:o| "Do something"].
22-
```
29+
```
2330
To also clear collections when they are returned add passivator
2431
```Smalltalk
2532
pool passivator:[:o|o removeAll].
26-
```
33+
```
2734
Or to do that before borrow add activator:
2835
```Smalltalk
2936
pool activator:[:o|o removeAll].
@@ -48,4 +55,3 @@ spec
4855
baseline: 'ObjectPool'
4956
with: [ spec repository: 'github://pharo-ide/ObjectPool:v1.0.0' ]
5057
```
51-

0 commit comments

Comments
 (0)