Skip to content

Commit c7ea692

Browse files
author
xp
committed
PasteShare v1.0.0
0 parents  commit c7ea692

210 files changed

Lines changed: 12206 additions & 0 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

.gitignore

Lines changed: 67 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,67 @@
1+
# Miscellaneous
2+
*.class
3+
*.log
4+
*.pyc
5+
*.swp
6+
.DS_Store
7+
.atom/
8+
.buildlog/
9+
.history
10+
.svn/
11+
12+
# IntelliJ related
13+
*.iml
14+
*.ipr
15+
*.iws
16+
.idea/
17+
18+
# The .vscode folder contains launch configuration and tasks you configure in
19+
# VS Code which you may wish to be included in version control, so this line
20+
# is commented out by default.
21+
#.vscode/
22+
23+
# Flutter/Dart/Pub related
24+
**/doc/api/
25+
**/ios/Flutter/.last_build_id
26+
.dart_tool/
27+
.flutter-plugins
28+
.flutter-plugins-dependencies
29+
.packages
30+
.pub-cache/
31+
.pub/
32+
/build/
33+
34+
# Web related
35+
lib/generated_plugin_registrant.dart
36+
37+
# Symbolication related
38+
app.*.symbols
39+
40+
# Obfuscation related
41+
app.*.map.json
42+
43+
# Android Studio will place build artifacts here
44+
/android/app/debug
45+
/android/app/profile
46+
/android/app/release
47+
48+
49+
flutter/ephemeral/
50+
out
51+
.vs
52+
53+
# Visual Studio user-specific files.
54+
*.suo
55+
*.user
56+
*.userosscache
57+
*.sln.docstates
58+
59+
# Visual Studio build-related files.
60+
x64/
61+
x86/
62+
63+
# Visual Studio cache files
64+
# files ending in .cache can be ignored
65+
*.[Cc]ache
66+
# but keep track of directories ending in .cache
67+
!*.[Cc]ache/

.metadata

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
# This file tracks properties of this Flutter project.
2+
# Used by Flutter tool to assess capabilities and perform upgrades etc.
3+
#
4+
# This file should be version controlled and should not be manually edited.
5+
6+
version:
7+
revision: c5a4b4029c0798f37c4a39b479d7cb75daa7b05c
8+
channel: stable
9+
10+
project_type: app

README.md

Lines changed: 26 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,26 @@
1+
![ScreensShot](./assets/web/favicon.ico)
2+
# PasteShare v1.0.0
3+
4+
A Cross-Platform ( macOS / iOS / Android / Windows / Ubuntu ) clipboard tool on LAN.
5+
6+
## Getting Started
7+
8+
### SSL
9+
10+
1. [how to generate a self signed ssl certificate using openssl](https://stackoverflow.com/questions/10175812/how-to-generate-a-self-signed-ssl-certificate-using-openssl)
11+
2. rename cert to `server_chain.pem` and rename key to `server_key.pem`
12+
3. mv them to `./assets/certificates`.
13+
4. trust your self-signed ssl certificate on `./lib/utils/http.dart` line 12.
14+
15+
### Flutter
16+
17+
For help getting started with Flutter, follow [online documentation](https://flutter.dev/docs)
18+
19+
20+
## Available on Apple App Store and Google Play
21+
22+
[https://lan.liuxuanping.com](https://lan.liuxuanping.com)
23+
24+
## ScreensShot
25+
26+
![ScreensShot](./assets/web/public-1617844480.8512568.png)

android/.gitignore

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
gradle-wrapper.jar
2+
/.gradle
3+
/captures/
4+
/gradlew
5+
/gradlew.bat
6+
/local.properties
7+
GeneratedPluginRegistrant.java
8+
9+
# Remember to never publicly share your keystore.
10+
# See https://flutter.dev/docs/deployment/android#reference-the-keystore-from-the-app
11+
key.properties

android/app/build.gradle

Lines changed: 74 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,74 @@
1+
def localProperties = new Properties()
2+
def localPropertiesFile = rootProject.file('local.properties')
3+
if (localPropertiesFile.exists()) {
4+
localPropertiesFile.withReader('UTF-8') { reader ->
5+
localProperties.load(reader)
6+
}
7+
}
8+
9+
def flutterRoot = localProperties.getProperty('flutter.sdk')
10+
if (flutterRoot == null) {
11+
throw new GradleException("Flutter SDK not found. Define location with flutter.sdk in the local.properties file.")
12+
}
13+
14+
def flutterVersionCode = localProperties.getProperty('flutter.versionCode')
15+
if (flutterVersionCode == null) {
16+
flutterVersionCode = '1'
17+
}
18+
19+
def flutterVersionName = localProperties.getProperty('flutter.versionName')
20+
if (flutterVersionName == null) {
21+
flutterVersionName = '1.0'
22+
}
23+
24+
apply plugin: 'com.android.application'
25+
apply plugin: 'kotlin-android'
26+
apply from: "$flutterRoot/packages/flutter_tools/gradle/flutter.gradle"
27+
28+
def keystoreProperties = new Properties()
29+
def keystorePropertiesFile = rootProject.file('key.properties')
30+
if (keystorePropertiesFile.exists()) {
31+
keystoreProperties.load(new FileInputStream(keystorePropertiesFile))
32+
}
33+
34+
android {
35+
compileSdkVersion 30
36+
37+
sourceSets {
38+
main.java.srcDirs += 'src/main/kotlin'
39+
}
40+
41+
defaultConfig {
42+
// TODO: Specify your own unique Application ID (https://developer.android.com/studio/build/application-id.html).
43+
applicationId "com.liuxuanping.local_area_network"
44+
minSdkVersion 21
45+
targetSdkVersion 30
46+
versionCode flutterVersionCode.toInteger()
47+
versionName flutterVersionName
48+
}
49+
50+
signingConfigs {
51+
release {
52+
keyAlias keystoreProperties['keyAlias']
53+
keyPassword keystoreProperties['keyPassword']
54+
storeFile keystoreProperties['storeFile'] ? file(keystoreProperties['storeFile']) : null
55+
storePassword keystoreProperties['storePassword']
56+
}
57+
}
58+
59+
buildTypes {
60+
release {
61+
// TODO: Add your own signing config for the release build.
62+
// Signing with the debug keys for now, so `flutter run --release` works.
63+
signingConfig signingConfigs.release
64+
}
65+
}
66+
}
67+
68+
flutter {
69+
source '../..'
70+
}
71+
72+
dependencies {
73+
implementation "org.jetbrains.kotlin:kotlin-stdlib-jdk7:$kotlin_version"
74+
}
Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
2+
package="com.liuxuanping.local_area_network">
3+
<!-- Flutter needs it to communicate with the running application
4+
to allow setting breakpoints, to provide hot reload, etc.
5+
-->
6+
<uses-permission android:name="android.permission.INTERNET"/>
7+
</manifest>
Lines changed: 99 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,99 @@
1+
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
2+
package="com.liuxuanping.local_area_network">
3+
4+
<uses-permission android:name="android.permission.INTERNET" />
5+
<uses-permission android:name="android.permission.ACCESS_NETWORK_STATE" />
6+
<uses-permission android:name="android.permission.READ_EXTERNAL_STORAGE"/>
7+
8+
<application
9+
android:icon="@mipmap/ic_launcher"
10+
android:label="@string/app_name">
11+
<activity
12+
android:name=".MainActivity"
13+
android:configChanges="orientation|keyboardHidden|keyboard|screenSize|smallestScreenSize|locale|layoutDirection|fontScale|screenLayout|density|uiMode"
14+
android:hardwareAccelerated="true"
15+
android:launchMode="singleInstance"
16+
android:theme="@style/LaunchTheme"
17+
android:windowSoftInputMode="adjustResize">
18+
<!-- Specifies an Android theme to apply to this Activity as soon as
19+
the Android process has started. This theme is visible to the user
20+
while the Flutter UI initializes. After that, this theme continues
21+
to determine the Window background behind the Flutter UI. -->
22+
<meta-data
23+
android:name="io.flutter.embedding.android.NormalTheme"
24+
android:resource="@style/NormalTheme" />
25+
<!-- Displays an Android View that continues showing the launch screen
26+
Drawable until Flutter paints its first frame, then this splash
27+
screen fades out. A splash screen is useful to avoid any visual
28+
gap between the end of Android's launch screen and the painting of
29+
Flutter's first frame. -->
30+
<meta-data
31+
android:name="io.flutter.embedding.android.SplashScreenDrawable"
32+
android:resource="@drawable/launch_background" />
33+
34+
<intent-filter>
35+
<action android:name="android.intent.action.MAIN" />
36+
<category android:name="android.intent.category.LAUNCHER" />
37+
</intent-filter>
38+
39+
40+
<!-- <intent-filter>-->
41+
<!-- <action android:name="android.intent.action.PROCESS_TEXT" />-->
42+
<!-- <category android:name="android.intent.category.DEFAULT" />-->
43+
<!-- <data android:mimeType="text/plain" />-->
44+
<!-- </intent-filter>-->
45+
<intent-filter>
46+
<action android:name="android.intent.action.SEND" />
47+
<category android:name="android.intent.category.DEFAULT" />
48+
<data android:mimeType="text/plain" />
49+
</intent-filter>
50+
<intent-filter>
51+
<action android:name="android.intent.action.SEND" />
52+
<category android:name="android.intent.category.DEFAULT" />
53+
<data android:mimeType="image/*" />
54+
</intent-filter>
55+
<intent-filter>
56+
<action android:name="android.intent.action.SEND_MULTIPLE" />
57+
<category android:name="android.intent.category.DEFAULT" />
58+
<data android:mimeType="image/*" />
59+
</intent-filter>
60+
<intent-filter>
61+
<action android:name="android.intent.action.SEND" />
62+
<category android:name="android.intent.category.DEFAULT" />
63+
<data android:mimeType="video/*" />
64+
</intent-filter>
65+
<intent-filter>
66+
<action android:name="android.intent.action.SEND_MULTIPLE" />
67+
<category android:name="android.intent.category.DEFAULT" />
68+
<data android:mimeType="video/*" />
69+
</intent-filter>
70+
<intent-filter>
71+
<action android:name="android.intent.action.SEND" />
72+
<category android:name="android.intent.category.DEFAULT" />
73+
<data android:mimeType="application/*" />
74+
</intent-filter>
75+
<intent-filter>
76+
<action android:name="android.intent.action.SEND_MULTIPLE" />
77+
<category android:name="android.intent.category.DEFAULT" />
78+
<data android:mimeType="application/*" />
79+
</intent-filter>
80+
<intent-filter>
81+
<action android:name="android.intent.action.SEND" />
82+
<category android:name="android.intent.category.DEFAULT" />
83+
<data android:mimeType="*/*" />
84+
</intent-filter>
85+
<intent-filter>
86+
<action android:name="android.intent.action.SEND_MULTIPLE" />
87+
<category android:name="android.intent.category.DEFAULT" />
88+
<data android:mimeType="*/*" />
89+
</intent-filter>
90+
</activity>
91+
<!-- Don't delete the meta-data below.
92+
This is used by the Flutter tool to generate GeneratedPluginRegistrant.java -->
93+
<meta-data
94+
android:name="flutterEmbedding"
95+
android:value="2" />
96+
<meta-data android:name="io.flutter.network-policy"
97+
android:resource="@xml/network_security_config"/>
98+
</application>
99+
</manifest>
11.8 KB
Loading

0 commit comments

Comments
 (0)