Skip to content

Commit 080d1f4

Browse files
authored
Merge pull request #11 from boterop/v2.5
v2.5.1
2 parents 9520895 + 83dc63c commit 080d1f4

File tree

10 files changed

+15622
-3088
lines changed

10 files changed

+15622
-3088
lines changed

.github/workflows/deploy.yml

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,13 @@
11
name: Publish Package to npmjs
22
on:
3-
release:
4-
types: [published]
3+
pull_request:
4+
branches:
5+
- main
6+
types: closed
7+
58
jobs:
69
build:
10+
if: ${{ github.event.pull_request.merged }}
711
runs-on: ubuntu-latest
812
steps:
913
- uses: actions/checkout@v4

.github/workflows/release.yml

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,6 @@ on:
44
pull_request:
55
branches:
66
- main
7-
- master
87
types: closed
98

109
jobs:

CHANGELOG.md

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,9 @@
11
# Changelog
22

3+
## 2.5.1 (27.04.2014)
4+
5+
- Update scope to correct installations
6+
37
## 2.5.0 (27.04.2024)
48

59
- Remove NativeEventEmitter warning

README.md

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -13,15 +13,15 @@ Emit event periodically (even when app is in the background).
1313
2. Install React Native Background Timer package.
1414

1515
```bash
16-
yarn add react-native-background-timer
16+
yarn add @boterop/react-native-background-timer
1717
# or using npm
18-
npm install react-native-background-timer --save
18+
npm install @boterop/react-native-background-timer --save
1919
```
2020

2121
3. Link React Native Background Timer library. This step is not necessary when you use React Native >= 0.60 (and your app is not ejected from Expo).
2222

2323
```bash
24-
react-native link react-native-background-timer
24+
react-native link @boterop/react-native-background-timer
2525
```
2626

2727
4. If you use CocoaPods or React Native >= 0.60 (and your app is not ejected from Expo) or your app is ejected from Expo, then before running your app on iOS, make sure you have CocoaPods installed and run:
@@ -57,7 +57,7 @@ Link the library manually if you get errors:
5757
- `android/app/src/main/java/com/your-app/MainApplication.java`
5858

5959
```diff
60-
+ import com.ocetnik.timer.BackgroundTimerPackage;
60+
+ import io.boterop.timer.BackgroundTimerPackage;
6161

6262
@Override
6363
protected List<ReactPackage> getPackages() {
@@ -75,15 +75,15 @@ Link the library manually if you get errors:
7575
- `ios/Podfile`
7676

7777
```diff
78-
+ pod 'react-native-background-timer', :path => '../node_modules/react-native-background-timer'
78+
+ pod '@boterop/react-native-background-timer', :path => '../node_modules/@boterop/react-native-background-timer'
7979
```
8080

8181
</details>
8282

8383
## Usage
8484

8585
```js
86-
import BackgroundTimer from 'react-native-background-timer';
86+
import BackgroundTimer from '@boterop/react-native-background-timer';
8787
```
8888

8989
### Crossplatform
@@ -157,7 +157,7 @@ import {
157157
Platform,
158158
} from 'react-native';
159159

160-
import BackgroundTimer from 'react-native-background-timer';
160+
import BackgroundTimer from '@boterop/react-native-background-timer';
161161
```
162162

163163
```js
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,3 @@
1-
<manifest xmlns:android="http://schemas.android.com/apk/res/android" package="com.ocetnik.timer">
1+
<manifest xmlns:android="http://schemas.android.com/apk/res/android" package="io.boterop.timer">
22
<uses-permission android:name="android.permission.WAKE_LOCK" />
33
</manifest>

android/src/main/java/com/ocetnik/timer/BackgroundTimerModule.java renamed to android/src/main/java/com/boterop/timer/BackgroundTimerModule.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
package com.ocetnik.timer;
1+
package io.boterop.timer;
22

33
import android.os.Handler;
44
import android.os.PowerManager;
@@ -36,7 +36,7 @@ public BackgroundTimerModule(ReactApplicationContext reactContext) {
3636
super(reactContext);
3737
this.reactContext = reactContext;
3838
this.powerManager = (PowerManager) getReactApplicationContext().getSystemService(reactContext.POWER_SERVICE);
39-
this.wakeLock = powerManager.newWakeLock(PowerManager.PARTIAL_WAKE_LOCK, "rohit_bg_wakelock");
39+
this.wakeLock = powerManager.newWakeLock(PowerManager.PARTIAL_WAKE_LOCK, "react-native-background-timer:wakelock");
4040
reactContext.addLifecycleEventListener(listener);
4141
}
4242

android/src/main/java/com/ocetnik/timer/BackgroundTimerPackage.java renamed to android/src/main/java/com/boterop/timer/BackgroundTimerPackage.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
package com.ocetnik.timer;
1+
package io.boterop.timer;
22

33
import com.facebook.react.ReactPackage;
44
import com.facebook.react.bridge.JavaScriptModule;

0 commit comments

Comments
 (0)