This file contains hidden or 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
/* | |
Create google sheet file with 'Data', 'Weather', 'Settings' sheets | |
Settings: //https://developers.google.com/nest/device-access/get-started | |
SDMUrl https://smartdevicemanagement.googleapis.com/v1 | |
projectId ... | |
nestDeviceId ... | |
oauthClientId ... | |
oauthClientSecret ... | |
oauthRefreshToken ... | |
oauthAccessToken ... |
This file contains hidden or 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
//be sure your hook folder is correct | |
//`git config core.hooksPath` | |
//or set it `git config core.hooksPath .git/hooks` | |
//be sure the sh.exe exists and it's correct | |
//file:prepare-commit-msg | |
#!C:/Program\ Files/Git/usr/bin/sh.exe | |
python ".git/hooks/prepare-commit-msg.py" "$1" | |
exit 0 |
This file contains hidden or 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.text.SimpleDateFormat | |
/* | |
this is very !naive! implementation by making just a copy of defined files (probably doesn't handle spaces or special chars!) | |
1) define following `backupMap` and `removeBeforeRestore` | |
2) import it into the app build.gradle using `apply from: "$rootProject.projectDir/appbackup.gradle"` | |
3) and then just run: | |
#backup (see the BackupID e.g. 20220307-113423) | |
./gradlew app:appBackup | |
#restore |
This file contains hidden or 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
@file:Suppress("LocalVariableName") | |
package com.scurab.neonimpl | |
import kotlin.math.ceil | |
import kotlin.math.cos | |
import kotlin.math.sin | |
/* | |
Implementation of https://rosettacode.org/wiki/Fast_Fourier_transform#C |
This file contains hidden or 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
#include <stdio.h> | |
#include <math.h> | |
#include <time.h> | |
//algorithm taken from | |
//https://rosettacode.org/wiki/Fast_Fourier_transform#C | |
//simplified version to remove double complex numbers dependency to see exactly what the code does | |
//(N log(N)) - complexity | |
typedef float fftn; |
This file contains hidden or 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
? | |
https://stackoverflow.com/questions/12334468/java-sign-certificate-programmatically-without-bc | |
https://www.programmersought.com/article/50962351573/ | |
https://github.com/apache/commons-crypto | |
https://deliciousbrains.com/ssl-certificate-authority-for-local-https-development/ | |
#Private CA key | |
openssl genrsa -des3 -out myCA.key 2048 | |
#Public CA certificate |
This file contains hidden or 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
#google calendar -> settings -> import | |
BEGIN:VCALENDAR | |
VERSION:2.0 | |
BEGIN:VEVENT | |
RRULE:FREQ=MONTHLY;INTERVAL=1;BYDAY=MO,TU,WE,TH,FR;BYSETPOS=-1;WKST=MO | |
SUMMARY:Invoicing | |
DTSTART;VALUE=DATE:20210430 | |
SEQUENCE:0 | |
DESCRIPTION:Invoicing. | |
END:VEVENT |
This file contains hidden or 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
private static def isAndroidApp(Project project) { | |
return project.plugins.findPlugin("com.android.application") != null | |
} | |
private static def isJavaLib(Project project) { | |
return project.plugins.findPlugin("java-library") != null | |
} | |
class ProjectDetails { | |
ProjectDetails(classDirs, srcDirs, buildDir, testTask) { |
This file contains hidden or 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
package com.kotlin | |
interface IEventName { | |
val eventName: String | |
} | |
interface IAnalyticsArgsEvent<T> : IEventName | |
interface IAnalyticsMapArgsEvent : IAnalyticsArgsEvent<Map<String, Any>> | |
class AnalyticsArgsEvent<T>(override val eventName: String) : IAnalyticsArgsEvent<T> | |
class AnalyticsMapArgsEvent(override val eventName: String) : IAnalyticsMapArgsEvent |
This file contains hidden or 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
// | |
// AppDelegate.m | |
// uitor | |
// | |
// Created by Jiri Bruchanov on 03/01/2020. | |
// Copyright © 2020 Jiri Bruchanov. All rights reserved. | |
// | |
//WEB Server https://github.com/swisspol/GCDWebServer |
NewerOlder