Skip to content

Instantly share code, notes, and snippets.

View jeffreyrr's full-sized avatar
🧠

Jeffrey Rogiers jeffreyrr

🧠
View GitHub Profile
private boolean isServiceRunning() {
ActivityManager manager = (ActivityManager) getSystemService(ACTIVITY_SERVICE);
for (RunningServiceInfo service : manager.getRunningServices(Integer.MAX_VALUE)){
if("com.example.MyNeatoIntentService".equals(service.service.getClassName())) {
return true;
}
}
return false;
}

CREATE

Clone an existing repository

$ git clone ssh://user@domain.com/repo.git

Create a new local repository

$ git init

LOCAL CHANGES

@jeffreyrr
jeffreyrr / pull_request_template.md
Last active March 24, 2022 15:46
Standard PR Template for Github (.github/pull_request_template.md)

Description

Sample Description Text.

Fixes:

Type of change

  • Bug fix (non-breaking change which fixes an issue)
@oianmol
oianmol / QrScannerScreen.android.kt
Last active June 13, 2024 12:23
QR Code Scanner with Jetbrains Jetpack compose multiplatform!
import android.Manifest
import android.content.pm.PackageManager
import android.util.Log
import android.view.ViewGroup
import androidx.activity.compose.rememberLauncherForActivityResult
import androidx.activity.result.contract.ActivityResultContracts
import androidx.camera.core.CameraSelector
import androidx.camera.core.ImageAnalysis
import androidx.camera.core.Preview
import androidx.camera.lifecycle.ProcessCameraProvider