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
🚴♂️ 2055km █████████████▊░░░░░░ | |
⛷ 454km ███░░░░░░░░░░░░░░░░░ | |
🚶♂️ 394km ██▌░░░░░░░░░░░░░░░░░ | |
🏃♂️ 52km ▏░░░░░░░░░░░░░░░░░░░ | |
2954km total |
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
🚴♂️ 5204km ████████████████▏░░░ | |
🚶♂️ 847km ██▌░░░░░░░░░░░░░░░░░ | |
🏃♂️ 170km ▍░░░░░░░░░░░░░░░░░░░ | |
⛷ 137km ▍░░░░░░░░░░░░░░░░░░░ | |
6357km total |
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
hello world |
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
// Run with $ node server.js | |
var http = require('http'); | |
var server = http.createServer(function (req, res) { | |
referrerPolicy = "strict-origin-when-cross-origin"; // Replace with corresponding test value | |
res.writeHead(200, { 'Content-Type': 'text/html', 'Referrer-Policy': referrerPolicy }); | |
res.write('<html><body>'); | |
res.write('<h1>Test page</h1>'); | |
res.write('<ul>'); | |
res.write('<li><a href="https://github.com">Cross-origin request</a></li>'); |
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
#!/usr/bin/env bash | |
# Download supplementary MIPS toolchains which have been removed from Android NDK r17 to fix Android RN builds | |
# Underlying issue is https://github.com/facebook/react-native/issues/19321 | |
set -e | |
NDK_BUNDLE_TOOLCHAINS=$ANDROID_HOME/ndk-bundle/toolchains | |
MIPS64_TOOLCHAIN=$NDK_BUNDLE_TOOLCHAINS/mips64el-linux-android-4.9/prebuilt/darwin-x86_64/bin | |
MIPS_TOOLCHAIN=$NDK_BUNDLE_TOOLCHAINS/mipsel-linux-android-4.9/prebuilt/darwin-x86_64/bin |
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
public class NotificationUtil { | |
public static Notification createNotification(Context context, PendingIntent pendingIntent, String title, String text, int iconId) { | |
Notification notification; | |
if (isNotificationBuilderSupported()) { | |
notification = buildNotificationWithBuilder(context, pendingIntent, title, text, iconId); | |
} else { | |
notification = buildNotificationPreHoneycomb(context, pendingIntent, title, text, iconId); | |
} | |
return notification; | |
} |
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
<idea-plugin version="2"> | |
<id>com.example.yourPluginID</id> | |
<name>A simple demo plugin</name> | |
<description>This is just a simple demo plugin with no other purpose</description> | |
<version>1.0</version> | |
<vendor url="http://www.ranterle.de">ranterle</vendor> | |
<idea-version since-build="135.1"/> | |
<depends>com.intellij.modules.java</depends> |
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
public class SignInAction extends AnAction { | |
@Override | |
public void actionPerformed(AnActionEvent event) { | |
Project project = event.getProject(); | |
// do your sign in work... | |
} | |
@Override | |
public void update(AnActionEvent e) { | |
e.getPresentation().setEnabledAndVisible(!isAuthenticated()); |
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
Intent i = new Intent(Intent.ACTION_VIEW); | |
i.setData("mycustomscheme://test"); | |
PackageManager manager = context.getPackageManager(); | |
List<ResolveInfo> resolvedActivites = manager.queryIntentActivities(i, PackageManager.MATCH_DEFAULT_ONLY); | |
if (!resolvedActivities.isEmpty()) { | |
// ... someone responds to the scheme | |
} else { | |
// ... nobody does | |
} |
NewerOlder