Skip to content

Instantly share code, notes, and snippets.

@jiaming0708
jiaming0708 / nginx-logrotate-windows.ps1
Last active December 15, 2023 08:23
nginx logrotate on windows
# nginx folder
$nginxFolder = "D:\nginx\logs"
# keep log count
$keepLogCount = 7
# Maximum log file size in megabytes
$maxLogFileSizeMB = 10
# date format
@jiaming0708
jiaming0708 / openssl_commands.md
Created March 25, 2023 00:41 — forked from Hakky54/openssl_commands.md
Some list of openssl commands for check and verify your keys

OpenSSL 🔐

Install

Install the OpenSSL on Debian based systems

sudo apt-get install openssl
@jiaming0708
jiaming0708 / main.dart
Created January 9, 2023 13:36
Flutter GoRouter with BottomNavigationBar
import 'package:flutter/material.dart';
import 'package:go_router/go_router.dart';
void main() {
runApp(const MyApp());
}
class MyApp extends StatelessWidget {
const MyApp({super.key});
@jiaming0708
jiaming0708 / reset.css
Created April 11, 2022 01:52
My css reset setting
html {
height: 100%;
}
body {
margin: 0;
-webkit-font-smoothing: antialiased;
-moz-osx-font-smoothing: grayscale;
height: 100%;
}
@jiaming0708
jiaming0708 / mac.md
Last active June 27, 2023 07:24
Software in computer
  • alfred
  • docker desktop
  • postman
  • bitwarden
  • vscode
  • typro
@jiaming0708
jiaming0708 / facade.cs
Last active August 6, 2021 03:03
design pattern sample
using System;
namespace DesignPattern.Facade
{ class Program
{
static void Main()
{
var employ = new 店員();
employ.買餅乾();
@jiaming0708
jiaming0708 / .mytheme.omp.json
Last active May 19, 2021 13:06
Oh-my-posh setting
{
"$schema": "https://raw.githubusercontent.com/JanDeDobbeleer/oh-my-posh/main/themes/schema.json",
"blocks": [
{
"alignment": "left",
"segments": [
{
"type": "root",
"style": "plain",
"foreground": "#FFEE58"
@jiaming0708
jiaming0708 / web.config
Last active April 20, 2021 01:32
IIS config for Gitea
<?xml version="1.0" encoding="UTF-8"?>
<configuration>
<system.webServer>
<security>
<requestFiltering>
<hiddenSegments>
<clear />
</hiddenSegments>
<denyUrlSequences>
<clear />
@jiaming0708
jiaming0708 / cralwer.json
Created March 27, 2019 03:20
detect is crawler
[
".*Java.*outbrain",
"008\\/",
"192\\.comAgent",
"2ip\\.ru",
"404checker",
"^bluefish ",
"^Calypso v\\/",
"^COMODO DCV",
"^DangDang",
@jiaming0708
jiaming0708 / HugeComponent.jsx
Last active March 13, 2019 13:09
React Component
function HugeComponent(){
return (
<div className={styles.root}>
{/* chat related content */}
<div className={styles.left}>
<div className={styles.top}>
{
showCancelPopup && (
<Modal
onClose={this.closePopup}