mirror of
https://github.com/bitsocialnet/5chan.git
synced 2026-08-03 07:41:04 +02:00
fix: rename invalid identifiers starting with digit to fivechan
This commit is contained in:
@@ -1,10 +1,10 @@
|
|||||||
apply plugin: 'com.android.application'
|
apply plugin: 'com.android.application'
|
||||||
|
|
||||||
android {
|
android {
|
||||||
namespace "5chan.android"
|
namespace "fivechan.android"
|
||||||
compileSdkVersion rootProject.ext.compileSdkVersion
|
compileSdkVersion rootProject.ext.compileSdkVersion
|
||||||
defaultConfig {
|
defaultConfig {
|
||||||
applicationId "5chan.android"
|
applicationId "fivechan.android"
|
||||||
minSdkVersion rootProject.ext.minSdkVersion
|
minSdkVersion rootProject.ext.minSdkVersion
|
||||||
targetSdkVersion rootProject.ext.targetSdkVersion
|
targetSdkVersion rootProject.ext.targetSdkVersion
|
||||||
versionCode 1
|
versionCode 1
|
||||||
|
|||||||
@@ -13,7 +13,7 @@
|
|||||||
|
|
||||||
<activity
|
<activity
|
||||||
android:configChanges="orientation|keyboardHidden|keyboard|screenSize|locale|smallestScreenSize|screenLayout|uiMode"
|
android:configChanges="orientation|keyboardHidden|keyboard|screenSize|locale|smallestScreenSize|screenLayout|uiMode"
|
||||||
android:name="5chan.android.MainActivity"
|
android:name="fivechan.android.MainActivity"
|
||||||
android:label="@string/title_activity_main"
|
android:label="@string/title_activity_main"
|
||||||
android:theme="@style/AppTheme.NoActionBarLaunch"
|
android:theme="@style/AppTheme.NoActionBarLaunch"
|
||||||
android:launchMode="singleTask"
|
android:launchMode="singleTask"
|
||||||
|
|||||||
@@ -1,5 +1,5 @@
|
|||||||
{
|
{
|
||||||
"appId": "5chan.android",
|
"appId": "fivechan.android",
|
||||||
"appName": "5chan",
|
"appName": "5chan",
|
||||||
"webDir": "build",
|
"webDir": "build",
|
||||||
"plugins": {
|
"plugins": {
|
||||||
|
|||||||
@@ -1,4 +1,4 @@
|
|||||||
package 5chan.android;
|
package fivechan.android;
|
||||||
|
|
||||||
import android.app.Activity;
|
import android.app.Activity;
|
||||||
import android.content.Intent;
|
import android.content.Intent;
|
||||||
|
|||||||
@@ -1,4 +1,4 @@
|
|||||||
package 5chan.android;
|
package fivechan.android;
|
||||||
|
|
||||||
import android.content.Context;
|
import android.content.Context;
|
||||||
import android.database.Cursor;
|
import android.database.Cursor;
|
||||||
|
|||||||
@@ -1,4 +1,4 @@
|
|||||||
package 5chan.android;
|
package fivechan.android;
|
||||||
|
|
||||||
import android.os.Bundle;
|
import android.os.Bundle;
|
||||||
import com.getcapacitor.BridgeActivity;
|
import com.getcapacitor.BridgeActivity;
|
||||||
|
|||||||
@@ -2,6 +2,6 @@
|
|||||||
<resources>
|
<resources>
|
||||||
<string name="app_name">5chan</string>
|
<string name="app_name">5chan</string>
|
||||||
<string name="title_activity_main">5chan</string>
|
<string name="title_activity_main">5chan</string>
|
||||||
<string name="package_name">5chan.android</string>
|
<string name="package_name">fivechan.android</string>
|
||||||
<string name="custom_url_scheme">5chan.android</string>
|
<string name="custom_url_scheme">fivechan.android</string>
|
||||||
</resources>
|
</resources>
|
||||||
|
|||||||
+1
-1
@@ -1,7 +1,7 @@
|
|||||||
import { CapacitorConfig } from '@capacitor/cli';
|
import { CapacitorConfig } from '@capacitor/cli';
|
||||||
|
|
||||||
const config: CapacitorConfig = {
|
const config: CapacitorConfig = {
|
||||||
appId: '5chan.android',
|
appId: 'fivechan.android',
|
||||||
appName: '5chan',
|
appName: '5chan',
|
||||||
webDir: 'build',
|
webDir: 'build',
|
||||||
plugins: {
|
plugins: {
|
||||||
|
|||||||
@@ -21,12 +21,12 @@ function createHtmlArchive() {
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
const zipBinPath = path.resolve(rootPath, 'node_modules', '7zip-bin', 'linux', 'x64', '7za');
|
const zipBinPath = path.resolve(rootPath, 'node_modules', '7zip-bin', 'linux', 'x64', '7za');
|
||||||
const 5chanHtmlFolderName = `5chan-html-${packageJson.version}`;
|
const fivechanHtmlFolderName = `5chan-html-${packageJson.version}`;
|
||||||
const outputFile = path.resolve(distFolderPath, `${5chanHtmlFolderName}.zip`);
|
const outputFile = path.resolve(distFolderPath, `${fivechanHtmlFolderName}.zip`);
|
||||||
const inputFolder = path.resolve(rootPath, 'build');
|
const inputFolder = path.resolve(rootPath, 'build');
|
||||||
try {
|
try {
|
||||||
execSync(`${zipBinPath} a ${outputFile} ${inputFolder}`);
|
execSync(`${zipBinPath} a ${outputFile} ${inputFolder}`);
|
||||||
execSync(`${zipBinPath} rn -r ${outputFile} build ${5chanHtmlFolderName}`);
|
execSync(`${zipBinPath} rn -r ${outputFile} build ${fivechanHtmlFolderName}`);
|
||||||
} catch (e) {
|
} catch (e) {
|
||||||
console.error('electron build createHtmlArchive error:', e);
|
console.error('electron build createHtmlArchive error:', e);
|
||||||
}
|
}
|
||||||
|
|||||||
+9
-9
@@ -16,22 +16,22 @@ if [ -z "${DEPLOY_USER+xxx}" ]; then echo "DEPLOY_USER not set" && exit; fi
|
|||||||
if [ -z "${DEPLOY_PASSWORD+xxx}" ]; then echo "DEPLOY_PASSWORD not set" && exit; fi
|
if [ -z "${DEPLOY_PASSWORD+xxx}" ]; then echo "DEPLOY_PASSWORD not set" && exit; fi
|
||||||
|
|
||||||
# save version
|
# save version
|
||||||
5chan_VERSION=$(node -e "console.log(require('../package.json').version)")
|
FIVECHAN_VERSION=$(node -e "console.log(require('../package.json').version)")
|
||||||
5chan_HTML_NAME="5chan-html-$5chan_VERSION"
|
FIVECHAN_HTML_NAME="5chan-html-$FIVECHAN_VERSION"
|
||||||
|
|
||||||
SCRIPT="
|
SCRIPT="
|
||||||
# download html
|
# download html
|
||||||
cd ~
|
cd ~
|
||||||
rm $5chan_HTML_NAME.zip
|
rm $FIVECHAN_HTML_NAME.zip
|
||||||
rm -fr $5chan_HTML_NAME
|
rm -fr $FIVECHAN_HTML_NAME
|
||||||
wget https://github.com/plebbit/5chan/releases/download/v$5chan_VERSION/$5chan_HTML_NAME.zip || exit
|
wget https://github.com/plebbit/5chan/releases/download/v$FIVECHAN_VERSION/$FIVECHAN_HTML_NAME.zip || exit
|
||||||
|
|
||||||
# extract html
|
# extract html
|
||||||
unzip $5chan_HTML_NAME.zip || exit
|
unzip $FIVECHAN_HTML_NAME.zip || exit
|
||||||
rm $5chan_HTML_NAME.zip || exit
|
rm $FIVECHAN_HTML_NAME.zip || exit
|
||||||
|
|
||||||
# add to ipfs
|
# add to ipfs
|
||||||
CID=\`ipfs add --recursive --pin --quieter $5chan_HTML_NAME | tail -n 1\`
|
CID=\`ipfs add --recursive --pin --quieter $FIVECHAN_HTML_NAME | tail -n 1\`
|
||||||
ipfs pin add --recursive \"\$CID\"
|
ipfs pin add --recursive \"\$CID\"
|
||||||
|
|
||||||
# start ipfs daemon if not started
|
# start ipfs daemon if not started
|
||||||
@@ -42,7 +42,7 @@ nohup ipfs daemon &
|
|||||||
sleep 3
|
sleep 3
|
||||||
echo \"\"
|
echo \"\"
|
||||||
CID=\`ipfs cid base32 \$CID\`
|
CID=\`ipfs cid base32 \$CID\`
|
||||||
echo $5chan_HTML_NAME \"CID: \$CID\"
|
echo $FIVECHAN_HTML_NAME \"CID: \$CID\"
|
||||||
echo \"\"
|
echo \"\"
|
||||||
"
|
"
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user