This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import java.math.BigInteger; | |
import java.nio.charset.StandardCharsets; | |
import java.security.MessageDigest; | |
import java.util.regex.Matcher; | |
import java.util.regex.Pattern; | |
public class GradleDigestUtils { | |
private static final String MD5_DIGEST = "MD5"; | |
private static final Pattern VERSION_PATTERN = Pattern.compile("^(.*?)-(src|bin|all)$"); | |
private static final String GRADLE_DOWNLOAD_URL = "https://services.gradle.org/distributions/gradle-%s.zip"; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
extensions.getByType<AppExtension>().apply { | |
applicationVariants.all { | |
addJavaSourceFoldersToModel(file("$buildDir/generated/ksp/$name/kotlin")) | |
} | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/sh | |
usage() { | |
if [ $1 == 1 ]; then | |
echo "MeetInLeeds Wi-Fi Login" | |
echo "Author: XFY9326" | |
echo "Website: https://xfy9326.github.io" | |
echo "" | |
fi | |
echo "Options:" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Reference: https://stackoverflow.com/questions/66341823/jetpack-compose-scrollbars/68056586#68056586 | |
// Modify: LazyListState -> ScrollState | |
fun Modifier.verticalScrollbar( | |
scrollState: ScrollState, | |
scrollBarWidth: Dp = 4.dp, | |
minScrollBarHeight: Dp = 5.dp, | |
scrollBarColor: Color = Color.Blue, | |
cornerRadius: Dp = 2.dp | |
): Modifier = composed { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import dataclasses | |
import dataclasses_json | |
from dataclasses_json import DataClassJsonMixin | |
@dataclasses.dataclass(frozen=True) | |
class Value(DataClassJsonMixin): | |
value_type: str = dataclasses.field(init=False, default="unknown", metadata=dataclasses_json.config(field_name="type")) |