Skip to content

Instantly share code, notes, and snippets.

View bozzelliandrea's full-sized avatar
🦥
trying to break things

Andrea Bozzelli bozzelliandrea

🦥
trying to break things
View GitHub Profile
@bozzelliandrea
bozzelliandrea / SpringMockitoMongoTest.java
Created August 15, 2022 12:27
Simple JUnit5 unit test class for a Spring business logic service, including Mockito used to mock a MongoRepository response
@TestInstance(TestInstance.Lifecycle.PER_CLASS)
@ExtendWith({SpringExtension.class, MockitoExtension.class})
public class StatsServiceTest {
private final Stats today;
@Mock
private StatsRepository statsRepository;
private StatsService statsService;
@bozzelliandrea
bozzelliandrea / latex-compiler.yml
Created September 26, 2022 16:16
Github Action - LaTex Compiler to PDF
name: LaTex Compiler to PDF
on:
push:
branches: [ main ]
paths: 'docs/**'
workflow_dispatch:
env:
FILE_PATH: docs/

How To Make A Working TWRP Device Tree For Your MediaTek Device & Start Building Them, Online

This Guide is tested on 64-bit mt6735/53 chipset device. It will also work on any 64-bit and 32-bit devices.

You will need something from your Stock ROM first. Get them all and Try to modify it using the procedure.

Note: This guide will be helpful for you if you have older mediatek devices (android-5.1 or android-6.0), but up-to-date devices can also work.

Update: This guide had a few typos and derps (Oops..), but I've tried to make it free of those now (Dated November 18, 2020)

Bonus: You can also use this tool by @SebaUbuntu, @yshalsager and @mauronofrio to auto generate the twrp tree. The tool is best if your device runs on android-9.0. The tools is still not 100% compatible to all devices, but I'll still recommend it and give it 8.5/10 in the scale of varsatility.

import lombok.NonNull;
import lombok.SneakyThrows;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import java.lang.reflect.Field;
import java.util.*;
public final class Resource {