mirror of
https://git.FreeBSD.org/ports.git
synced 2025-01-02 06:03:50 +00:00
Add atom 1.44.0, hackable text editor for the 21st century.
Many thanks to the maintainer Hiroki for his very appreciated work on it.
This commit is contained in:
parent
a5d0b46567
commit
3bd4ee6968
Notes:
svn2git
2021-03-31 03:12:20 +00:00
svn path=/head/; revision=526528
@ -10,6 +10,7 @@
|
||||
SUBDIR += aewan
|
||||
SUBDIR += apel
|
||||
SUBDIR += asedit
|
||||
SUBDIR += atom
|
||||
SUBDIR += beav
|
||||
SUBDIR += biew
|
||||
SUBDIR += bitedit
|
||||
|
251
editors/atom/Makefile
Normal file
251
editors/atom/Makefile
Normal file
@ -0,0 +1,251 @@
|
||||
# $FreeBSD$
|
||||
|
||||
PORTNAME= atom
|
||||
DISTVERSIONPREFIX= v
|
||||
DISTVERSION= 1.44.0
|
||||
CATEGORIES= editors
|
||||
MASTER_SITES= https://nodejs.org/dist/v${APM_NODE_VER}/:node \
|
||||
https://github.com/tagattie/FreeBSD-Atom/releases/download/v1.42.0/:jasmine_tagged \
|
||||
https://github.com/tagattie/FreeBSD-Atom/releases/download/${DISTVERSIONFULL}/:npm_cache
|
||||
PKGNAMESUFFIX= -ide
|
||||
DISTFILES= node-v${APM_NODE_VER}${EXTRACT_SUFX}:node \
|
||||
jasmine-tagged-1.1.4.tar.gz:jasmine_tagged \
|
||||
atom-npm-cache-${DISTVERSION}${EXTRACT_SUFX}:npm_cache \
|
||||
atom-apm-cache-${DISTVERSION}${EXTRACT_SUFX}:npm_cache
|
||||
|
||||
MAINTAINER= tagattie@yandex.com
|
||||
COMMENT= Hackable text editor for the 21st century
|
||||
|
||||
LICENSE= MIT
|
||||
LICENSE_FILE= ${WRKSRC}/LICENSE.md
|
||||
|
||||
ONLY_FOR_ARCHS= amd64
|
||||
|
||||
BUILD_DEPENDS= zip:archivers/zip \
|
||||
electron${ELECTRON_VER_MAJOR}:devel/electron${ELECTRON_VER_MAJOR} \
|
||||
bash:shells/bash \
|
||||
rg:textproc/ripgrep \
|
||||
node:www/node10 \
|
||||
npm:www/npm-node10
|
||||
LIB_DEPENDS= libatk-bridge-2.0.so:accessibility/at-spi2-atk \
|
||||
libsnappy.so:archivers/snappy \
|
||||
libasound.so:audio/alsa-lib \
|
||||
libFLAC.so:audio/flac \
|
||||
libopus.so:audio/opus \
|
||||
libdbus-1.so:devel/dbus \
|
||||
libinotify.so:devel/libinotify \
|
||||
libnotify.so:devel/libnotify \
|
||||
libpci.so:devel/libpci \
|
||||
libnspr4.so:devel/nspr \
|
||||
libpcre2-8.so:devel/pcre2 \
|
||||
libdrm.so:graphics/libdrm \
|
||||
libwebp.so:graphics/webp \
|
||||
libavcodec.so:multimedia/ffmpeg \
|
||||
libopenh264.so:multimedia/openh264 \
|
||||
libcups.so:print/cups \
|
||||
libfreetype.so:print/freetype2 \
|
||||
libharfbuzz.so:print/harfbuzz \
|
||||
libsecret-1.so:security/libsecret \
|
||||
libnss3.so:security/nss \
|
||||
libexpat.so:textproc/expat2 \
|
||||
libfontconfig.so:x11-fonts/fontconfig
|
||||
RUN_DEPENDS= git:devel/git \
|
||||
xdg-open:devel/xdg-utils \
|
||||
bash:shells/bash
|
||||
TEST_DEPENDS= bash:shells/bash
|
||||
|
||||
USES= desktop-file-utils gl gnome jpeg localbase:ldflags pkgconfig \
|
||||
python:2.7 shebangfix xorg
|
||||
|
||||
USE_GITHUB= yes
|
||||
|
||||
.include "${.CURDIR}/../../devel/electron4/Makefile.version"
|
||||
APM_NODE_VER= 10.2.1
|
||||
|
||||
BINARY_ALIAS= python=${PYTHON_CMD}
|
||||
|
||||
USE_XORG= x11 xcb xcomposite xcursor xdamage xext xfixes xi xkbfile \
|
||||
xrandr xrender xscrnsaver xtst
|
||||
USE_GL= gl glesv2
|
||||
USE_GNOME= atk cairo pango gtk30 libxml2 libxslt
|
||||
INSTALLS_ICONS= yes
|
||||
|
||||
USE_LDCONFIG= ${DATADIR}
|
||||
|
||||
SHEBANG_FILES= atom.sh
|
||||
SHEBANG_FILES_APM= apm/node_modules/atom-package-manager/bin/apm \
|
||||
apm/node_modules/atom-package-manager/bin/npm \
|
||||
apm/node_modules/atom-package-manager/bin/python-interceptor.sh \
|
||||
apm/node_modules/atom-package-manager/script/postinstall.sh \
|
||||
apm/node_modules/atom-package-manager/node_modules/npm/configure \
|
||||
apm/node_modules/atom-package-manager/node_modules/npm/lib/utils/completion.sh \
|
||||
apm/node_modules/atom-package-manager/node_modules/npm/node_modules/node-gyp/gyp/gyp \
|
||||
apm/node_modules/atom-package-manager/node_modules/npm/node_modules/node-gyp/gyp/samples/samples \
|
||||
apm/node_modules/atom-package-manager/node_modules/npm/scripts/clean-old.sh \
|
||||
apm/node_modules/atom-package-manager/node_modules/npm/scripts/dep-update \
|
||||
apm/node_modules/atom-package-manager/node_modules/npm/scripts/dev-dep-update \
|
||||
apm/node_modules/atom-package-manager/node_modules/npm/scripts/relocate.sh \
|
||||
|
||||
pre-everything::
|
||||
@${ECHO_MSG} ""
|
||||
@${ECHO_MSG} "The limit imposed by poudriere(8) for the maximum number of files allowed to be"
|
||||
@${ECHO_MSG} "opened by a jail (default 1024) is exceeded during the build of ${PORTNAME}."
|
||||
@${ECHO_MSG} "To successfully build ${PORTNAME} with poudriere(8), you must add the following"
|
||||
@${ECHO_MSG} "line to poudriere.conf:"
|
||||
@${ECHO_MSG} "MAX_FILES_${PORTNAME}${PKGNAMESUFFIX:C/-/_/}=4096"
|
||||
@${ECHO_MSG} ""
|
||||
|
||||
post-extract:
|
||||
# copy linux keymaps and menus files
|
||||
cd ${WRKSRC}/keymaps && ${CP} linux.cson freebsd.cson
|
||||
cd ${WRKSRC}/menus && ${CP} linux.cson freebsd.cson
|
||||
|
||||
post-patch:
|
||||
${REINPLACE_CMD} -E 's|("electronVersion":.*").*(")|\1${ELECTRON_VER}\2|' \
|
||||
${WRKSRC}/package.json
|
||||
${REINPLACE_CMD} -e 's|/usr/share|${PREFIX}/share|g' \
|
||||
${WRKSRC}/script/lib/install-application.js
|
||||
${REINPLACE_CMD} -e 's|<%= installDir %>|${PREFIX}|' \
|
||||
${WRKSRC}/resources/linux/atom.desktop.in
|
||||
|
||||
pre-build: build-apm-node bootstrap-script bootstrap-apm bootstrap-atom clean-backup
|
||||
build-apm-node:
|
||||
cd ${WRKDIR}/node-v${APM_NODE_VER} && \
|
||||
${SETENV} ${CONFIGURE_ENV} CC=${CC} CXX=${CXX} ./configure && \
|
||||
${SETENV} ${MAKE_ENV} ${BSDMAKE} -j ${MAKE_JOBS_NUMBER}
|
||||
bootstrap-script:
|
||||
cd ${WRKSRC}/script && ${SETENV} ${MAKE_ENV} \
|
||||
npm install --ignore-scripts --offline
|
||||
for p in ${PATCHDIR}/script/patch-*; do \
|
||||
${PATCH} -p0 -d ${WRKSRC} < $${p}; \
|
||||
done
|
||||
cd ${WRKSRC}/script && ${SETENV} ${MAKE_ENV} \
|
||||
npm_config_build_from_source=true \
|
||||
npm_config_offline=true \
|
||||
npm rebuild --nodedir=${LOCALBASE}
|
||||
bootstrap-apm:
|
||||
cd ${WRKSRC}/apm && ${SETENV} ${MAKE_ENV} \
|
||||
npm install --global-style --ignore-scripts --offline
|
||||
for p in ${PATCHDIR}/apm/patch-*; do \
|
||||
${PATCH} -p0 -d ${WRKSRC} < $${p}; \
|
||||
done
|
||||
cd ${WRKSRC} && ${FIND} ${SHEBANG_FILES_APM} -type f \
|
||||
-exec ${SED} -i '' -e 's|#!/bin/bash|#!${LOCALBASE}/bin/bash|' \
|
||||
-e 's|#!/usr/bin/python|#!${PYTHON_CMD}|' \
|
||||
-e 's|exec python|exec ${PYTHON_VERSION}|' {} ';'
|
||||
cd ${WRKSRC}/apm/node_modules/atom-package-manager/node_modules/npm/node_modules/node-gyp && \
|
||||
${FIND} . -type f -name '*.py' -exec ${SED} -i '' \
|
||||
-e 's|#!/usr/bin/env python|#!${PYTHON_CMD}|' {} ';'
|
||||
${CP} ${WRKDIR}/node-v${APM_NODE_VER}/out/Release/node \
|
||||
${WRKSRC}/apm/node_modules/atom-package-manager/bin && \
|
||||
${STRIP_CMD} ${WRKSRC}/apm/node_modules/atom-package-manager/bin/node
|
||||
cd ${WRKSRC}/apm/node_modules/atom-package-manager && \
|
||||
${SETENV} ${MAKE_ENV} \
|
||||
npm_config_build_from_source=true \
|
||||
npm_config_offline=true \
|
||||
npm_config_target=${APM_NODE_VER} \
|
||||
npm rebuild --nodedir=${WRKDIR}/node-v${APM_NODE_VER} && \
|
||||
${SETENV} ${MAKE_ENV} \
|
||||
npm_config_build_from_source=true \
|
||||
npm_config_offline=true \
|
||||
npm_config_target=${APM_NODE_VER} \
|
||||
npm dedupe --nodedir=${WRKDIR}/node-v${APM_NODE_VER}
|
||||
bootstrap-atom:
|
||||
cd ${WRKSRC} && ${SETENV} ${MAKE_ENV} \
|
||||
ATOM_RESOURCE_PATH=${WRKSRC} \
|
||||
npm_config_target=${ELECTRON_VER} \
|
||||
npm_config_ignore_scripts=true \
|
||||
npm_config_offline=true \
|
||||
./apm/node_modules/atom-package-manager/bin/apm install
|
||||
for p in ${PATCHDIR}/atom/patch-*; do \
|
||||
${PATCH} -p0 -d ${WRKSRC} < $${p}; \
|
||||
done
|
||||
${MKDIR} ${WRKSRC}/node_modules/vscode-ripgrep/bin
|
||||
${CP} ${LOCALBASE}/bin/rg ${WRKSRC}/node_modules/vscode-ripgrep/bin
|
||||
cd ${WRKSRC} && ${SETENV} ${MAKE_ENV} \
|
||||
ATOM_RESOURCE_PATH=${WRKSRC} \
|
||||
npm_config_target=${ELECTRON_VER} \
|
||||
npm_config_build_from_source=true \
|
||||
npm_config_nodedir=${LOCALBASE}/share/electron${ELECTRON_VER_MAJOR}/node_headers \
|
||||
npm_config_offline=true \
|
||||
./apm/node_modules/atom-package-manager/bin/apm rebuild
|
||||
clean-backup:
|
||||
cd ${WRKSRC} && ${FIND} . \( -name '*.bak' -o -name '*.orig' -o -name '*~' \) -print -delete
|
||||
|
||||
do-build:
|
||||
# setup download cache for electron-packager
|
||||
${MKDIR} ${WRKSRC}/electron
|
||||
cd ${LOCALBASE}/share/electron${ELECTRON_VER_MAJOR} && \
|
||||
zip -q -r ${WRKSRC}/electron/electron-v${ELECTRON_VER}-freebsd-x64.zip .
|
||||
cd ${WRKSRC}/electron && \
|
||||
${SHA256} -r *-v${ELECTRON_VER}-freebsd-*.zip | \
|
||||
${SED} -e 's/ / */' > SHASUMS256.txt-${ELECTRON_VER}
|
||||
# build atom
|
||||
cd ${WRKSRC} && ${SETENV} ${MAKE_ENV} \
|
||||
npm_config_target=${ELECTRON_VER} \
|
||||
npm_config_build_from_source=true \
|
||||
npm_config_nodedir=${LOCALBASE}/share/electron${ELECTRON_VER_MAJOR}/node_headers \
|
||||
npm_config_offline=true \
|
||||
./script/build --no-bootstrap
|
||||
|
||||
do-install:
|
||||
${MKDIR} ${STAGEDIR}${PREFIX}/share/icons/hicolor
|
||||
cd ${WRKSRC} && ${SETENV} ${MAKE_ENV} XDG_DATA_DIRS=${STAGEDIR}${PREFIX}/share \
|
||||
npm_config_build_from_source=true \
|
||||
npm_config_offline=true \
|
||||
./script/build --no-bootstrap --existing-binaries --install=${STAGEDIR}${PREFIX}
|
||||
.for f in chromedriver mksnapshot v8_context_snapshot_generator
|
||||
${RM} ${STAGEDIR}${DATADIR}/${f}
|
||||
.endfor
|
||||
${RM} -r ${STAGEDIR}${DATADIR}/node_headers
|
||||
cd ${STAGEDIR}${DATADIR}/resources/app/apm && \
|
||||
${FIND} . -type f -name '*.node' -exec ${STRIP_CMD} {} ';'
|
||||
cd ${STAGEDIR}${DATADIR}/resources/app.asar.unpacked && \
|
||||
${FIND} . -type f -name '*.node' -exec ${STRIP_CMD} {} ';'
|
||||
|
||||
do-test:
|
||||
# Note: Xvfb or something similar is necessary for headless testing
|
||||
# core main process tests
|
||||
cd ${WRKSRC} && ${SETENV} ${TEST_ENV} ./script/test
|
||||
# bundled package tests
|
||||
cd ${WRKSRC} && ${SETENV} ${TEST_ENV} ./script/test --package
|
||||
|
||||
# Helper targets for port maintainers
|
||||
make-npm-cache:
|
||||
# do "make patch" before executing this target
|
||||
cd ${WRKDIR} && ${RM} -r .npm
|
||||
cd ${WRKSRC}/script && \
|
||||
${SETENV} HOME=${WRKDIR} npm install --ignore-scripts
|
||||
cd ${WRKSRC}/apm && \
|
||||
${SETENV} HOME=${WRKDIR} npm install --ignore-scripts
|
||||
cd ${WRKDIR}/.npm && \
|
||||
${RM} -r _locks anonymous-cli-metrics.json
|
||||
cd ${WRKDIR} && \
|
||||
${TAR} -czf atom-npm-cache-${DISTVERSION}${EXTRACT_SUFX} .npm
|
||||
|
||||
make-apm-cache:
|
||||
# do up to "make bootstrap-apm" before executing this target
|
||||
cd ${WRKDIR} && ${RM} -r .atom
|
||||
cd ${WRKSRC} && ${SETENV} ${MAKE_ENV} \
|
||||
ATOM_RESOURCE_PATH=${WRKSRC} \
|
||||
npm_config_target=${ELECTON_VER} \
|
||||
npm_config_ignore_scripts=true \
|
||||
${WRKSRC}/apm/node_modules/atom-package-manager/bin/apm install
|
||||
cd ${WRKSRC}/node_modules && \
|
||||
for p in `${AWK} '/packageDependencies.*{/,/}/' ${WRKSRC}/package.json | \
|
||||
${SED} -e '1d; $$d' | ${AWK} -F ': ' '{print $$1}' | ${SED} -e 's/"//g'`; do \
|
||||
${ECHO_CMD} "Installing modules for $${p}"; \
|
||||
cd ${WRKSRC}/node_modules/$${p} && ${SETENV} ${MAKE_ENV} \
|
||||
ATOM_RESOURCE_PATH=${WRKSRC} \
|
||||
npm_config_target=${ELECTON_VER} \
|
||||
npm_config_ignore_scripts=true \
|
||||
${WRKSRC}/apm/node_modules/atom-package-manager/bin/apm install; \
|
||||
done
|
||||
cd ${WRKDIR}/.atom && \
|
||||
${RM} -r .node-gyp packages
|
||||
cd ${WRKDIR}/.atom/.apm && \
|
||||
${RM} -r .apmrc _locks anonymous-cli-metrics.json index-v5
|
||||
cd ${WRKDIR} && \
|
||||
${TAR} -czf atom-apm-cache-${DISTVERSION}${EXTRACT_SUFX} .atom
|
||||
|
||||
.include <bsd.port.mk>
|
11
editors/atom/distinfo
Normal file
11
editors/atom/distinfo
Normal file
@ -0,0 +1,11 @@
|
||||
TIMESTAMP = 1581749918
|
||||
SHA256 (node-v10.2.1.tar.gz) = dcdba29f6b933969d6a8a36ea91cfd44bcb500a1e582a3273ac3d4d930e721e4
|
||||
SIZE (node-v10.2.1.tar.gz) = 35757099
|
||||
SHA256 (jasmine-tagged-1.1.4.tar.gz) = 8988597858ddf9e9ba3333a19d8651691c8384117bf2e362e8a5ba193ed47585
|
||||
SIZE (jasmine-tagged-1.1.4.tar.gz) = 3071259
|
||||
SHA256 (atom-npm-cache-1.44.0.tar.gz) = 0dcab4ae60f05add0ffc0bddc45542fa9de58095e1e4c195b7fe6da07871fd3f
|
||||
SIZE (atom-npm-cache-1.44.0.tar.gz) = 42467992
|
||||
SHA256 (atom-apm-cache-1.44.0.tar.gz) = 4426bd88a55c9521d850eea01859dc6d2dff7f202115206c97c0ee342f9ec1bd
|
||||
SIZE (atom-apm-cache-1.44.0.tar.gz) = 115336084
|
||||
SHA256 (atom-atom-v1.44.0_GH0.tar.gz) = 8d79697b0c969f22ee8dc2c1d27c608036e92deaf63574f8cd1509ea506eded9
|
||||
SIZE (atom-atom-v1.44.0_GH0.tar.gz) = 11909698
|
@ -0,0 +1,11 @@
|
||||
--- apm/node_modules/atom-package-manager/lib/apm.js.orig 2019-12-27 05:56:26 UTC
|
||||
+++ apm/node_modules/atom-package-manager/lib/apm.js
|
||||
@@ -72,7 +72,7 @@
|
||||
}
|
||||
return callback(`${appLocation}/Contents/Resources/app.asar`);
|
||||
});
|
||||
- case 'linux':
|
||||
+ case 'linux': case 'freebsd':
|
||||
appLocation = '/usr/local/share/atom/resources/app.asar';
|
||||
if (!fs.existsSync(appLocation)) {
|
||||
appLocation = '/usr/share/atom/resources/app.asar';
|
@ -0,0 +1,11 @@
|
||||
--- apm/node_modules/atom-package-manager/lib/auth.js.orig 2019-12-27 05:53:35 UTC
|
||||
+++ apm/node_modules/atom-package-manager/lib/auth.js
|
||||
@@ -6,7 +6,7 @@
|
||||
} catch (error1) {
|
||||
error = error1;
|
||||
// Gracefully handle keytar failing to load due to missing library on Linux
|
||||
- if (process.platform === 'linux') {
|
||||
+ if (process.platform === 'linux' || process.platform === 'freebsd') {
|
||||
keytar = {
|
||||
findPassword: function() {
|
||||
return Promise.reject();
|
@ -0,0 +1,11 @@
|
||||
--- apm/node_modules/atom-package-manager/lib/install.js.orig 2019-12-27 05:57:00 UTC
|
||||
+++ apm/node_modules/atom-package-manager/lib/install.js
|
||||
@@ -159,7 +159,7 @@
|
||||
case 'win32':
|
||||
message += "\nYou can install Git by downloading, installing, and launching GitHub for Windows: https://windows.github.com\n";
|
||||
break;
|
||||
- case 'linux':
|
||||
+ case 'linux': case 'freebsd':
|
||||
message += "\nYou can install Git from your OS package manager.\n";
|
||||
}
|
||||
message += "\nRun apm -v after installing Git to see what version has been detected.";
|
@ -0,0 +1,12 @@
|
||||
--- node_modules/@atom/nsfw/binding.gyp.orig 1985-10-26 08:15:00 UTC
|
||||
+++ node_modules/@atom/nsfw/binding.gyp
|
||||
@@ -97,6 +97,9 @@
|
||||
["OS=='freebsd'", {
|
||||
"include_dirs": [
|
||||
"/usr/local/include"
|
||||
+ ],
|
||||
+ "ldflags": [
|
||||
+ "-L/usr/local/lib", "-linotify"
|
||||
]
|
||||
}],
|
||||
]
|
@ -0,0 +1,11 @@
|
||||
--- node_modules/@atom/watcher/binding.gyp.orig 1985-10-26 08:15:00 UTC
|
||||
+++ node_modules/@atom/watcher/binding.gyp
|
||||
@@ -66,7 +66,7 @@
|
||||
"src/worker/windows/windows_worker_platform.cpp"
|
||||
]
|
||||
}],
|
||||
- ["OS=='linux'", {
|
||||
+ ["OS=='linux' or OS=='freebsd'", {
|
||||
"defines": [
|
||||
'PLATFORM_LINUX'
|
||||
],
|
@ -0,0 +1,20 @@
|
||||
--- node_modules/atom-keymap/lib/helpers.js.orig 1985-10-26 08:15:00 UTC
|
||||
+++ node_modules/atom-keymap/lib/helpers.js
|
||||
@@ -218,7 +218,7 @@
|
||||
if (KEY_NAMES_BY_KEYBOARD_EVENT_CODE[code] != null) {
|
||||
key = KEY_NAMES_BY_KEYBOARD_EVENT_CODE[code];
|
||||
}
|
||||
- if (process.platform === 'linux') {
|
||||
+ if (process.platform === 'linux' || process.platform === 'freebsd') {
|
||||
if (code === 'NumpadDecimal' && !event.getModifierState('NumLock')) {
|
||||
key = 'delete';
|
||||
}
|
||||
@@ -257,7 +257,7 @@
|
||||
altKey = false;
|
||||
isAltModifiedKey = true;
|
||||
}
|
||||
- } else if (process.platform === 'linux') {
|
||||
+ } else if (process.platform === 'linux' || process.platform === 'freebsd') {
|
||||
nonAltModifiedKey = nonAltModifiedKeyForKeyboardEvent(event);
|
||||
if (nonAltModifiedKey && (ctrlKey || altKey || metaKey)) {
|
||||
key = nonAltModifiedKey;
|
@ -0,0 +1,52 @@
|
||||
--- node_modules/dugite/build/lib/git-environment.js.orig 1985-10-26 08:15:00 UTC
|
||||
+++ node_modules/dugite/build/lib/git-environment.js
|
||||
@@ -3,7 +3,7 @@ Object.defineProperty(exports, "__esModule", { value:
|
||||
const path = require("path");
|
||||
function resolveEmbeddedGitDir() {
|
||||
if (process.platform === 'darwin' ||
|
||||
- process.platform === 'linux' ||
|
||||
+ process.platform === 'linux' || process.platform === 'freebsd' ||
|
||||
process.platform === 'android' ||
|
||||
process.platform === 'win32') {
|
||||
const s = path.sep;
|
||||
@@ -23,6 +23,9 @@ function resolveGitDir() {
|
||||
if (process.env.LOCAL_GIT_DIRECTORY != null) {
|
||||
return path.resolve(process.env.LOCAL_GIT_DIRECTORY);
|
||||
}
|
||||
+ else if (process.platform === 'freebsd') {
|
||||
+ return '/usr/local';
|
||||
+ }
|
||||
else {
|
||||
return resolveEmbeddedGitDir();
|
||||
}
|
||||
@@ -94,13 +97,13 @@ function setupEnvironment(environmentVariables) {
|
||||
delete env.Path;
|
||||
}
|
||||
}
|
||||
- if (process.platform === 'darwin' || process.platform === 'linux') {
|
||||
+ if (process.platform === 'darwin' || process.platform === 'linux' || process.platform === 'freebsd') {
|
||||
// templates are used to populate your .git folder
|
||||
// when a repository is initialized locally
|
||||
const templateDir = `${gitDir}/share/git-core/templates`;
|
||||
env.GIT_TEMPLATE_DIR = templateDir;
|
||||
}
|
||||
- if (process.platform === 'linux') {
|
||||
+ if (process.platform === 'linux' || process.platform === 'freebsd') {
|
||||
// when building Git for Linux and then running it from
|
||||
// an arbitrary location, you should set PREFIX for the
|
||||
// process to ensure that it knows how to resolve things
|
||||
@@ -109,11 +112,11 @@ function setupEnvironment(environmentVariables) {
|
||||
// use the SSL certificate bundle included in the distribution only
|
||||
// when using embedded Git and not providing your own bundle
|
||||
const distDir = resolveEmbeddedGitDir();
|
||||
- const sslCABundle = `${distDir}/ssl/cacert.pem`;
|
||||
+ const sslCABundle = `/etc/ssl/cert.pem`;
|
||||
env.GIT_SSL_CAINFO = sslCABundle;
|
||||
}
|
||||
}
|
||||
return { env, gitLocation };
|
||||
}
|
||||
exports.setupEnvironment = setupEnvironment;
|
||||
-//# sourceMappingURL=git-environment.js.map
|
||||
\ No newline at end of file
|
||||
+//# sourceMappingURL=git-environment.js.map
|
@ -0,0 +1,11 @@
|
||||
--- node_modules/fs-admin/binding.gyp.orig 1985-10-26 08:15:00 UTC
|
||||
+++ node_modules/fs-admin/binding.gyp
|
||||
@@ -37,7 +37,7 @@
|
||||
'$(SDKROOT)/System/Library/Frameworks/Security.framework',
|
||||
],
|
||||
}],
|
||||
- ['OS=="linux"', {
|
||||
+ ['OS=="linux" or OS=="freebsd"', {
|
||||
'sources': [
|
||||
'src/fs-admin-linux.cc',
|
||||
],
|
@ -0,0 +1,9 @@
|
||||
--- node_modules/github/bin/linux-ssh-wrapper.sh.orig 2020-02-15 07:03:49 UTC
|
||||
+++ node_modules/github/bin/linux-ssh-wrapper.sh
|
||||
@@ -26,5 +26,5 @@ if type setsid >/dev/null 2>&1; then
|
||||
setsid ${SSH_CMD} "${@:-}"
|
||||
else
|
||||
log "no setsid available. SSH prompts may appear on a tty."
|
||||
- sh -c "${SSH_CMD} ${@:-}"
|
||||
+ ${SSH_CMD} "${@:-}"
|
||||
fi
|
@ -0,0 +1,11 @@
|
||||
--- node_modules/github/lib/git-shell-out-strategy.js.orig 2019-12-11 03:24:32 UTC
|
||||
+++ node_modules/github/lib/git-shell-out-strategy.js
|
||||
@@ -190,7 +190,7 @@ export default class GitShellOutStrategy {
|
||||
env.SSH_ASKPASS = normalizeGitHelperPath(gitTempDir.getAskPassSh());
|
||||
env.GIT_ASKPASS = normalizeGitHelperPath(gitTempDir.getAskPassSh());
|
||||
|
||||
- if (process.platform === 'linux') {
|
||||
+ if (process.platform === 'linux' || process.platform === 'freebsd') {
|
||||
env.GIT_SSH_COMMAND = gitTempDir.getSshWrapperSh();
|
||||
} else if (process.env.GIT_SSH_COMMAND) {
|
||||
env.GIT_SSH_COMMAND = process.env.GIT_SSH_COMMAND;
|
@ -0,0 +1,11 @@
|
||||
--- node_modules/github/lib/models/workdir-context.js.orig 2019-08-21 13:55:10 UTC
|
||||
+++ node_modules/github/lib/models/workdir-context.js
|
||||
@@ -116,7 +116,7 @@ export default class WorkdirContext {
|
||||
}
|
||||
|
||||
useWorkspaceChangeObserver() {
|
||||
- return !!process.env.ATOM_GITHUB_WORKSPACE_OBSERVER || process.platform === 'linux';
|
||||
+ return !!process.env.ATOM_GITHUB_WORKSPACE_OBSERVER || (process.platform === 'linux' || process.platform === 'freebsd');
|
||||
}
|
||||
|
||||
// Event subscriptions
|
@ -0,0 +1,10 @@
|
||||
--- node_modules/github/package.json.orig 2020-02-15 07:00:39 UTC
|
||||
+++ node_modules/github/package.json
|
||||
@@ -215,7 +215,6 @@
|
||||
"dedent-js": "1.0.1",
|
||||
"electron-devtools-installer": "2.2.4",
|
||||
"electron-link": "0.4.0",
|
||||
- "electron-mksnapshot": "^4.2.0",
|
||||
"enzyme": "3.10.0",
|
||||
"enzyme-adapter-react-16": "1.7.1",
|
||||
"eslint": "6.7.0",
|
@ -0,0 +1,11 @@
|
||||
--- node_modules/github/test/git-strategies.test.js.orig 2019-12-11 03:24:32 UTC
|
||||
+++ node_modules/github/test/git-strategies.test.js
|
||||
@@ -1535,7 +1535,7 @@ import * as reporterProxy from '../lib/reporter-proxy'
|
||||
assert.match(options.env.DISPLAY, /^.+$/);
|
||||
assert.match(options.env.SSH_ASKPASS, /git-askpass-atom\.sh$/);
|
||||
assert.match(options.env.GIT_ASKPASS, /git-askpass-atom\.sh$/);
|
||||
- if (process.platform === 'linux') {
|
||||
+ if (process.platform === 'linux' || process.platform === 'freebsd') {
|
||||
assert.match(options.env.GIT_SSH_COMMAND, /linux-ssh-wrapper\.sh$/);
|
||||
}
|
||||
|
@ -0,0 +1,20 @@
|
||||
--- node_modules/github/test/github-package.test.js.orig 2019-12-11 02:42:35 UTC
|
||||
+++ node_modules/github/test/github-package.test.js
|
||||
@@ -935,7 +935,7 @@ describe('GithubPackage', function() {
|
||||
|
||||
describe('when a file change is made outside Atom in workspace 1', function() {
|
||||
beforeEach(function() {
|
||||
- if (process.platform === 'linux') {
|
||||
+ if (process.platform === 'linux' || process.platform === 'freebsd') {
|
||||
this.skip();
|
||||
}
|
||||
|
||||
@@ -953,7 +953,7 @@ describe('GithubPackage', function() {
|
||||
|
||||
describe('when a file change is made outside Atom in workspace 2', function() {
|
||||
beforeEach(function() {
|
||||
- if (process.platform === 'linux') {
|
||||
+ if (process.platform === 'linux' || process.platform === 'freebsd') {
|
||||
this.skip();
|
||||
}
|
||||
|
@ -0,0 +1,11 @@
|
||||
--- node_modules/nslog/binding.gyp.orig 1985-10-26 08:15:00 UTC
|
||||
+++ node_modules/nslog/binding.gyp
|
||||
@@ -33,7 +33,7 @@
|
||||
'src/nslog_win.cc',
|
||||
],
|
||||
}],
|
||||
- ['OS=="linux"', {
|
||||
+ ['OS=="linux" or OS=="freebsd"', {
|
||||
'sources': [
|
||||
'src/nslog_linux.cc',
|
||||
],
|
@ -0,0 +1,11 @@
|
||||
--- node_modules/os-homedir/index.js.orig 2015-07-20 23:25:14 UTC
|
||||
+++ node_modules/os-homedir/index.js
|
||||
@@ -14,7 +14,7 @@ function homedir() {
|
||||
return home || (user ? '/Users/' + user : null);
|
||||
}
|
||||
|
||||
- if (process.platform === 'linux') {
|
||||
+ if (process.platform === 'linux' || process.platform === 'freebsd') {
|
||||
return home || (process.getuid() === 0 ? '/root' : (user ? '/home/' + user : null));
|
||||
}
|
||||
|
@ -0,0 +1,16 @@
|
||||
--- node_modules/scrollbar-style/binding.gyp.orig 2015-01-28 01:01:40 UTC
|
||||
+++ node_modules/scrollbar-style/binding.gyp
|
||||
@@ -33,11 +33,11 @@
|
||||
4996, # function was declared deprecated
|
||||
],
|
||||
}], # OS=="win"
|
||||
- ['OS=="linux"', {
|
||||
+ ['OS=="linux" or OS=="freebsd"', {
|
||||
"sources": [
|
||||
"src/scrollbar-style-observer-non-mac.cc",
|
||||
],
|
||||
- }], # OS=="linux"
|
||||
+ }], # OS=="linux" or OS=="freebsd"
|
||||
]
|
||||
}
|
||||
]
|
@ -0,0 +1,12 @@
|
||||
--- node_modules/spell-check/lib/system-checker.coffee.orig 2019-12-27 08:04:33 UTC
|
||||
+++ node_modules/spell-check/lib/system-checker.coffee
|
||||
@@ -65,6 +65,9 @@ class SystemChecker
|
||||
searchPaths.push "/usr/share/myspell"
|
||||
searchPaths.push "/usr/share/myspell/dicts"
|
||||
|
||||
+ if /freebsd/.test process.platform
|
||||
+ searchPaths.push "/usr/local/share/hunspell"
|
||||
+
|
||||
# OS X uses the following paths.
|
||||
if /darwin/.test process.platform
|
||||
searchPaths.push "/"
|
@ -0,0 +1,20 @@
|
||||
--- node_modules/spellchecker/binding.gyp.orig 1985-10-26 08:15:00 UTC
|
||||
+++ node_modules/spellchecker/binding.gyp
|
||||
@@ -4,7 +4,7 @@
|
||||
['OS=="mac"', {
|
||||
'spellchecker_use_hunspell%': 'true',
|
||||
}],
|
||||
- ['OS=="linux"', {
|
||||
+ ['OS=="linux" or OS=="freebsd"', {
|
||||
'spellchecker_use_hunspell': 'true',
|
||||
}],
|
||||
['OS=="win"', {
|
||||
@@ -53,7 +53,7 @@
|
||||
'src/transcoder_win.cc',
|
||||
],
|
||||
}],
|
||||
- ['OS=="linux"', {
|
||||
+ ['OS=="linux" or OS=="freebsd"', {
|
||||
'sources': [
|
||||
'src/spellchecker_linux.cc',
|
||||
'src/transcoder_posix.cc',
|
@ -0,0 +1,102 @@
|
||||
--- node_modules/spellchecker/vendor/hunspell/src/hunspell/affentry.hxx.orig 2019-12-27 07:21:39 UTC
|
||||
+++ node_modules/spellchecker/vendor/hunspell/src/hunspell/affentry.hxx
|
||||
@@ -24,10 +24,10 @@ class LIBHUNSPELL_DLL_EXPORTED PfxEntry : protected Af
|
||||
~PfxEntry();
|
||||
|
||||
inline bool allowCross() { return ((opts & aeXPRODUCT) != 0); }
|
||||
- struct hentry * checkword(const char * word, int len, char in_compound,
|
||||
+ struct hentry * checkword(const char * word, int len, char in_compound,
|
||||
const FLAG needflag = FLAG_NULL);
|
||||
|
||||
- struct hentry * check_twosfx(const char * word, int len, char in_compound, const FLAG needflag = NULL);
|
||||
+ struct hentry * check_twosfx(const char * word, int len, char in_compound, const FLAG needflag = FLAG_NULL);
|
||||
|
||||
char * check_morph(const char * word, int len, char in_compound,
|
||||
const FLAG needflag = FLAG_NULL);
|
||||
@@ -36,15 +36,15 @@ class LIBHUNSPELL_DLL_EXPORTED PfxEntry : protected Af
|
||||
char in_compound, const FLAG needflag = FLAG_NULL);
|
||||
|
||||
inline FLAG getFlag() { return aflag; }
|
||||
- inline const char * getKey() { return appnd; }
|
||||
+ inline const char * getKey() { return appnd; }
|
||||
char * add(const char * word, int len);
|
||||
|
||||
- inline short getKeyLen() { return appndl; }
|
||||
+ inline short getKeyLen() { return appndl; }
|
||||
|
||||
- inline const char * getMorph() { return morphcode; }
|
||||
+ inline const char * getMorph() { return morphcode; }
|
||||
|
||||
- inline const unsigned short * getCont() { return contclass; }
|
||||
- inline short getContLen() { return contclasslen; }
|
||||
+ inline const unsigned short * getCont() { return contclass; }
|
||||
+ inline short getContLen() { return contclasslen; }
|
||||
|
||||
inline PfxEntry * getNext() { return next; }
|
||||
inline PfxEntry * getNextNE() { return nextne; }
|
||||
@@ -55,7 +55,7 @@ class LIBHUNSPELL_DLL_EXPORTED PfxEntry : protected Af
|
||||
inline void setNextNE(PfxEntry * ptr) { nextne = ptr; }
|
||||
inline void setNextEQ(PfxEntry * ptr) { nexteq = ptr; }
|
||||
inline void setFlgNxt(PfxEntry * ptr) { flgnxt = ptr; }
|
||||
-
|
||||
+
|
||||
inline char * nextchar(char * p);
|
||||
inline int test_condition(const char * st);
|
||||
};
|
||||
@@ -74,7 +74,7 @@ class LIBHUNSPELL_DLL_EXPORTED SfxEntry : protected Af
|
||||
SfxEntry * nexteq;
|
||||
SfxEntry * nextne;
|
||||
SfxEntry * flgnxt;
|
||||
-
|
||||
+
|
||||
SfxEntry * l_morph;
|
||||
SfxEntry * r_morph;
|
||||
SfxEntry * eq_morph;
|
||||
@@ -85,32 +85,32 @@ class LIBHUNSPELL_DLL_EXPORTED SfxEntry : protected Af
|
||||
~SfxEntry();
|
||||
|
||||
inline bool allowCross() { return ((opts & aeXPRODUCT) != 0); }
|
||||
- struct hentry * checkword(const char * word, int len, int optflags,
|
||||
+ struct hentry * checkword(const char * word, int len, int optflags,
|
||||
PfxEntry* ppfx, char ** wlst, int maxSug, int * ns,
|
||||
// const FLAG cclass = FLAG_NULL, const FLAG needflag = FLAG_NULL, char in_compound=IN_CPD_NOT);
|
||||
const FLAG cclass = FLAG_NULL, const FLAG needflag = FLAG_NULL, const FLAG badflag = 0);
|
||||
|
||||
- struct hentry * check_twosfx(const char * word, int len, int optflags, PfxEntry* ppfx, const FLAG needflag = NULL);
|
||||
+ struct hentry * check_twosfx(const char * word, int len, int optflags, PfxEntry* ppfx, const FLAG needflag = FLAG_NULL);
|
||||
|
||||
char * check_twosfx_morph(const char * word, int len, int optflags,
|
||||
PfxEntry* ppfx, const FLAG needflag = FLAG_NULL);
|
||||
struct hentry * get_next_homonym(struct hentry * he);
|
||||
- struct hentry * get_next_homonym(struct hentry * word, int optflags, PfxEntry* ppfx,
|
||||
+ struct hentry * get_next_homonym(struct hentry * word, int optflags, PfxEntry* ppfx,
|
||||
const FLAG cclass, const FLAG needflag);
|
||||
|
||||
|
||||
inline FLAG getFlag() { return aflag; }
|
||||
- inline const char * getKey() { return rappnd; }
|
||||
+ inline const char * getKey() { return rappnd; }
|
||||
char * add(const char * word, int len);
|
||||
|
||||
|
||||
- inline const char * getMorph() { return morphcode; }
|
||||
+ inline const char * getMorph() { return morphcode; }
|
||||
|
||||
- inline const unsigned short * getCont() { return contclass; }
|
||||
- inline short getContLen() { return contclasslen; }
|
||||
- inline const char * getAffix() { return appnd; }
|
||||
+ inline const unsigned short * getCont() { return contclass; }
|
||||
+ inline short getContLen() { return contclasslen; }
|
||||
+ inline const char * getAffix() { return appnd; }
|
||||
|
||||
- inline short getKeyLen() { return appndl; }
|
||||
+ inline short getKeyLen() { return appndl; }
|
||||
|
||||
inline SfxEntry * getNext() { return next; }
|
||||
inline SfxEntry * getNextNE() { return nextne; }
|
||||
@@ -132,5 +132,3 @@ class LIBHUNSPELL_DLL_EXPORTED SfxEntry : protected Af
|
||||
};
|
||||
|
||||
#endif
|
||||
-
|
||||
-
|
@ -0,0 +1,11 @@
|
||||
--- node_modules/symbols-view/lib/tag-generator.js.orig 2019-12-27 07:45:34 UTC
|
||||
+++ node_modules/symbols-view/lib/tag-generator.js
|
||||
@@ -79,7 +79,7 @@ export default class TagGenerator {
|
||||
generate() {
|
||||
let tags = {};
|
||||
const packageRoot = this.getPackageRoot();
|
||||
- const command = path.join(packageRoot, 'vendor', `ctags-${process.platform}`);
|
||||
+ const command = 'ctags';
|
||||
const defaultCtagsFile = path.join(packageRoot, 'lib', 'ctags-config');
|
||||
const args = [`--options=${defaultCtagsFile}`, '--fields=+KS'];
|
||||
|
@ -0,0 +1,11 @@
|
||||
--- node_modules/tabs/lib/tab-bar-view.coffee.orig 2019-01-24 00:42:27 UTC
|
||||
+++ node_modules/tabs/lib/tab-bar-view.coffee
|
||||
@@ -462,7 +462,7 @@ class TabBarView
|
||||
|
||||
updateTabScrolling: (value) ->
|
||||
if value is 'platform'
|
||||
- @tabScrolling = (process.platform is 'linux')
|
||||
+ @tabScrolling = (process.platform is 'linux' or process.platform is 'freebsd')
|
||||
else
|
||||
@tabScrolling = value
|
||||
|
@ -0,0 +1,11 @@
|
||||
--- node_modules/text-buffer/lib/text-buffer.js.orig 2019-12-27 06:41:17 UTC
|
||||
+++ node_modules/text-buffer/lib/text-buffer.js
|
||||
@@ -1925,7 +1925,7 @@ class TextBuffer {
|
||||
try {
|
||||
await this.buffer.save(destination, this.getEncoding())
|
||||
} catch (error) {
|
||||
- const canEscalate = process.platform === 'darwin' || process.platform === 'linux'
|
||||
+ const canEscalate = process.platform === 'darwin' || process.platform === 'linux' || process.platform === 'freebsd'
|
||||
if (error.code === 'EACCES' && destination === filePath && canEscalate) {
|
||||
const fsAdmin = require('fs-admin')
|
||||
try {
|
@ -0,0 +1,11 @@
|
||||
--- node_modules/tree-view/lib/root-drag-and-drop.coffee.orig 2019-05-14 21:29:00 UTC
|
||||
+++ node_modules/tree-view/lib/root-drag-and-drop.coffee
|
||||
@@ -42,7 +42,7 @@ class RootDragAndDropHandler
|
||||
|
||||
e.dataTransfer.setData 'text/plain', directory.path
|
||||
|
||||
- if process.platform in ['darwin', 'linux']
|
||||
+ if process.platform in ['darwin', 'linux', 'freebsd']
|
||||
pathUri = "file://#{directory.path}" unless @uriHasProtocol(directory.path)
|
||||
e.dataTransfer.setData 'text/uri-list', pathUri
|
||||
|
@ -0,0 +1,11 @@
|
||||
--- node_modules/tree-view/spec/tree-view-package-spec.coffee.orig 2019-12-27 06:42:40 UTC
|
||||
+++ node_modules/tree-view/spec/tree-view-package-spec.coffee
|
||||
@@ -5054,7 +5054,7 @@ describe "TreeView", ->
|
||||
treeView.rootDragAndDrop.onDragStart(dragStartEvent)
|
||||
|
||||
expect(dragStartEvent.dataTransfer.getData("text/plain")).toEqual gammaDirPath
|
||||
- if process.platform in ['darwin', 'linux']
|
||||
+ if process.platform in ['darwin', 'linux', 'freebsd']
|
||||
expect(dragStartEvent.dataTransfer.getData("text/uri-list")).toEqual "file://#{gammaDirPath}"
|
||||
|
||||
describe "when a root folder is dropped from another Atom window", ->
|
@ -0,0 +1,11 @@
|
||||
--- node_modules/user-home/index.js.orig 2019-12-27 06:43:28 UTC
|
||||
+++ node_modules/user-home/index.js
|
||||
@@ -7,7 +7,7 @@ if (process.platform === 'win32') {
|
||||
module.exports = env.USERPROFILE || env.HOMEDRIVE + env.HOMEPATH || home || null;
|
||||
} else if (process.platform === 'darwin') {
|
||||
module.exports = home || (user ? '/Users/' + user : null) || null;
|
||||
-} else if (process.platform === 'linux') {
|
||||
+} else if (process.platform === 'linux' || process.platform === 'freebsd') {
|
||||
module.exports = home ||
|
||||
(user ? (process.getuid() === 0 ? '/root' : '/home/' + user) : null) || null;
|
||||
} else {
|
20
editors/atom/files/patch-atom.sh
Normal file
20
editors/atom/files/patch-atom.sh
Normal file
@ -0,0 +1,20 @@
|
||||
--- atom.sh.orig 2019-05-22 03:44:37 UTC
|
||||
+++ atom.sh
|
||||
@@ -2,6 +2,8 @@
|
||||
|
||||
if [ "$(uname)" == 'Darwin' ]; then
|
||||
OS='Mac'
|
||||
+elif [ "$(uname)" == 'FreeBSD' ]; then
|
||||
+ OS='FreeBSD'
|
||||
elif [ "$(expr substr $(uname -s) 1 5)" == 'Linux' ]; then
|
||||
OS='Linux'
|
||||
else
|
||||
@@ -149,7 +151,7 @@ if [ $OS == 'Mac' ]; then
|
||||
else
|
||||
open -a "$ATOM_PATH/$ATOM_APP_NAME" -n --args --executed-from="$(pwd)" --pid=$$ --path-environment="$PATH" "$@"
|
||||
fi
|
||||
-elif [ $OS == 'Linux' ]; then
|
||||
+elif [ $OS == 'Linux' ] || [ $OS == 'FreeBSD' ]; then
|
||||
SCRIPT=$(readlink -f "$0")
|
||||
USR_DIRECTORY=$(readlink -f $(dirname $SCRIPT)/..)
|
||||
|
11
editors/atom/files/patch-package.json
Normal file
11
editors/atom/files/patch-package.json
Normal file
@ -0,0 +1,11 @@
|
||||
--- package.json.orig 2019-12-29 05:23:50 UTC
|
||||
+++ package.json
|
||||
@@ -74,7 +74,7 @@
|
||||
"incompatible-packages": "file:packages/incompatible-packages",
|
||||
"jasmine-json": "~0.0",
|
||||
"jasmine-reporters": "1.1.0",
|
||||
- "jasmine-tagged": "^1.1.4",
|
||||
+ "jasmine-tagged": "file:../jasmine-tagged",
|
||||
"key-path-helpers": "^0.4.0",
|
||||
"keybinding-resolver": "https://www.atom.io/api/packages/keybinding-resolver/versions/0.39.0/tarball",
|
||||
"language-c": "https://www.atom.io/api/packages/language-c/versions/0.60.18/tarball",
|
11
editors/atom/files/patch-packages_welcome_lib_guide-view.js
Normal file
11
editors/atom/files/patch-packages_welcome_lib_guide-view.js
Normal file
@ -0,0 +1,11 @@
|
||||
--- packages/welcome/lib/guide-view.js.orig 2019-12-27 05:12:53 UTC
|
||||
+++ packages/welcome/lib/guide-view.js
|
||||
@@ -380,7 +380,7 @@ export default class GuideView {
|
||||
getApplicationMenuName() {
|
||||
if (process.platform === 'darwin') {
|
||||
return 'Atom';
|
||||
- } else if (process.platform === 'linux') {
|
||||
+ } else if (process.platform === 'linux' || process.platform === 'freebsd') {
|
||||
return 'Edit';
|
||||
} else {
|
||||
return 'File';
|
20
editors/atom/files/patch-script_build
Normal file
20
editors/atom/files/patch-script_build
Normal file
@ -0,0 +1,20 @@
|
||||
--- script/build.orig 2019-10-21 17:33:40 UTC
|
||||
+++ script/build
|
||||
@@ -68,7 +68,7 @@ process.env.ELECTRON_VERSION = CONFIG.appMetadata.elec
|
||||
let binariesPromise = Promise.resolve()
|
||||
|
||||
if (!argv.existingBinaries) {
|
||||
- checkChromedriverVersion()
|
||||
+ // checkChromedriverVersion()
|
||||
cleanOutputDirectory()
|
||||
copyAssets()
|
||||
transpilePackagesWithCustomTranspilerPaths()
|
||||
@@ -88,7 +88,7 @@ if (!argv.existingBinaries) {
|
||||
if (!argv.generateApiDocs) {
|
||||
binariesPromise
|
||||
.then(packageApplication)
|
||||
- .then(packagedAppPath => generateStartupSnapshot(packagedAppPath).then(() => packagedAppPath))
|
||||
+ // .then(packagedAppPath => generateStartupSnapshot(packagedAppPath).then(() => packagedAppPath))
|
||||
.then(packagedAppPath => {
|
||||
switch (process.platform) {
|
||||
case 'darwin': {
|
14
editors/atom/files/patch-script_lib_dump-symbols.js
Normal file
14
editors/atom/files/patch-script_lib_dump-symbols.js
Normal file
@ -0,0 +1,14 @@
|
||||
--- script/lib/dump-symbols.js.orig 2019-10-21 17:33:40 UTC
|
||||
+++ script/lib/dump-symbols.js
|
||||
@@ -6,9 +6,9 @@ const path = require('path');
|
||||
|
||||
const CONFIG = require('../config');
|
||||
module.exports = function() {
|
||||
- if (process.platform === 'win32') {
|
||||
+ if (process.platform === 'win32' || process.platform === 'freebsd') {
|
||||
console.log(
|
||||
- 'Skipping symbol dumping because minidump is not supported on Windows'
|
||||
+ 'Skipping symbol dumping because minidump is not supported on Windows or FreeBSD'
|
||||
.gray
|
||||
);
|
||||
return Promise.resolve();
|
29
editors/atom/files/patch-script_lib_package-application.js
Normal file
29
editors/atom/files/patch-script_lib_package-application.js
Normal file
@ -0,0 +1,29 @@
|
||||
--- script/lib/package-application.js.orig 2019-10-21 17:33:40 UTC
|
||||
+++ script/lib/package-application.js
|
||||
@@ -66,7 +66,7 @@ module.exports = function() {
|
||||
'Resources'
|
||||
);
|
||||
setAtomHelperVersion(packagedAppPath);
|
||||
- } else if (process.platform === 'linux') {
|
||||
+ } else if (process.platform === 'linux' || process.platform === 'freebsd') {
|
||||
bundledResourcesPath = path.join(packagedAppPath, 'resources');
|
||||
chmodNodeFiles(packagedAppPath);
|
||||
} else {
|
||||
@@ -118,7 +118,7 @@ function copyNonASARResources(packagedAppPath, bundled
|
||||
path.join(CONFIG.repositoryRootPath, 'resources', 'mac', 'file.icns'),
|
||||
path.join(bundledResourcesPath, 'file.icns')
|
||||
);
|
||||
- } else if (process.platform === 'linux') {
|
||||
+ } else if (process.platform === 'linux' || process.platform === 'freebsd') {
|
||||
fs.copySync(
|
||||
path.join(
|
||||
CONFIG.repositoryRootPath,
|
||||
@@ -234,7 +234,7 @@ function renamePackagedAppDir(packageOutputDirPath) {
|
||||
path.join(packageOutputDirPath, appBundleName),
|
||||
packagedAppPath
|
||||
);
|
||||
- } else if (process.platform === 'linux') {
|
||||
+ } else if (process.platform === 'linux' || process.platform === 'freebsd') {
|
||||
const appName =
|
||||
CONFIG.channel !== 'stable' ? `atom-${CONFIG.channel}` : 'atom';
|
||||
let architecture;
|
20
editors/atom/files/patch-script_package.json
Normal file
20
editors/atom/files/patch-script_package.json
Normal file
@ -0,0 +1,20 @@
|
||||
--- script/package.json.orig 2019-12-13 19:07:42 UTC
|
||||
+++ script/package.json
|
||||
@@ -10,9 +10,7 @@
|
||||
"coffeelint": "1.15.7",
|
||||
"colors": "1.1.2",
|
||||
"donna": "1.0.16",
|
||||
- "electron-chromedriver": "^4.2.0",
|
||||
"electron-link": "0.4.0",
|
||||
- "electron-mksnapshot": "^4.2.0",
|
||||
"electron-packager": "12.2.0",
|
||||
"@atom/electron-winstaller": "0.0.1",
|
||||
"eslint": "^5.16.0",
|
||||
@@ -31,7 +29,6 @@
|
||||
"legal-eagle": "0.14.0",
|
||||
"lodash.startcase": "4.4.0",
|
||||
"lodash.template": "4.5.0",
|
||||
- "minidump": "0.9.0",
|
||||
"mkdirp": "0.5.1",
|
||||
"normalize-package-data": "2.3.5",
|
||||
"npm": "6.2.0",
|
20
editors/atom/files/patch-script_test
Normal file
20
editors/atom/files/patch-script_test
Normal file
@ -0,0 +1,20 @@
|
||||
--- script/test.orig 2019-12-13 19:07:42 UTC
|
||||
+++ script/test
|
||||
@@ -51,7 +51,7 @@ if (process.platform === 'darwin') {
|
||||
const executablePaths = glob.sync(path.join(CONFIG.buildOutputPath, '*.app'))
|
||||
assert(executablePaths.length === 1, `More than one application to run tests against was found. ${executablePaths.join(',')}`)
|
||||
executablePath = path.join(executablePaths[0], 'Contents', 'MacOS', path.basename(executablePaths[0], '.app'))
|
||||
-} else if (process.platform === 'linux') {
|
||||
+} else if (process.platform === 'linux' || process.platform === 'freebsd') {
|
||||
const executablePaths = glob.sync(path.join(CONFIG.buildOutputPath, 'atom-*', 'atom'))
|
||||
assert(executablePaths.length === 1, `More than one application to run tests against was found. ${executablePaths.join(',')}`)
|
||||
executablePath = executablePaths[0]
|
||||
@@ -215,7 +215,7 @@ function testSuitesForPlatform (platform) {
|
||||
case 'win32':
|
||||
suites = (process.arch === 'x64') ? [runCoreMainProcessTests, runCoreRenderProcessTests] : [runCoreMainProcessTests]
|
||||
break
|
||||
- case 'linux':
|
||||
+ case 'linux': case 'freebsd':
|
||||
suites = [runCoreMainProcessTests]
|
||||
break
|
||||
default:
|
@ -0,0 +1,11 @@
|
||||
--- spec/main-process/atom-application.test.js.orig 2019-11-16 08:38:38 UTC
|
||||
+++ spec/main-process/atom-application.test.js
|
||||
@@ -1107,7 +1107,7 @@ describe('AtomApplication', function() {
|
||||
});
|
||||
|
||||
describe('when closing the last window', function() {
|
||||
- if (process.platform === 'linux' || process.platform === 'win32') {
|
||||
+ if (process.platform === 'linux' || process.platform === 'freebsd' || process.platform === 'win32') {
|
||||
it('quits the application', async function() {
|
||||
const [w] = await scenario.launch(parseCommandLine(['a']));
|
||||
scenario.getApplication(0).removeWindow(w);
|
11
editors/atom/files/patch-src_atom-paths.js
Normal file
11
editors/atom/files/patch-src_atom-paths.js
Normal file
@ -0,0 +1,11 @@
|
||||
--- src/atom-paths.js.orig 2019-12-13 19:07:42 UTC
|
||||
+++ src/atom-paths.js
|
||||
@@ -19,7 +19,7 @@ const getAppDirectory = () => {
|
||||
0,
|
||||
process.execPath.indexOf('.app') + 4
|
||||
);
|
||||
- case 'linux':
|
||||
+ case 'linux': case 'freebsd':
|
||||
case 'win32':
|
||||
return path.join(process.execPath, '..');
|
||||
}
|
17
editors/atom/files/patch-src_config-schema.js
Normal file
17
editors/atom/files/patch-src_config-schema.js
Normal file
@ -0,0 +1,17 @@
|
||||
--- src/config-schema.js.orig 2019-10-21 17:33:40 UTC
|
||||
+++ src/config-schema.js
|
||||
@@ -614,12 +614,12 @@ const configSchema = {
|
||||
}
|
||||
};
|
||||
|
||||
-if (['win32', 'linux'].includes(process.platform)) {
|
||||
+if (['win32', 'linux', 'freebsd'].includes(process.platform)) {
|
||||
configSchema.core.properties.autoHideMenuBar = {
|
||||
type: 'boolean',
|
||||
default: false,
|
||||
description:
|
||||
- 'Automatically hide the menu bar and toggle it by pressing Alt. This is only supported on Windows & Linux.'
|
||||
+ 'Automatically hide the menu bar and toggle it by pressing Alt. This is only supported on Windows, Linux & FreeBSD.'
|
||||
};
|
||||
}
|
||||
|
18
editors/atom/files/patch-src_crash-reporter-start.js
Normal file
18
editors/atom/files/patch-src_crash-reporter-start.js
Normal file
@ -0,0 +1,18 @@
|
||||
--- src/crash-reporter-start.js.orig 2019-10-21 17:33:40 UTC
|
||||
+++ src/crash-reporter-start.js
|
||||
@@ -1,15 +1,2 @@
|
||||
module.exports = function(params) {
|
||||
- const { crashReporter } = require('electron');
|
||||
- const os = require('os');
|
||||
- const platformRelease = os.release();
|
||||
- const arch = os.arch();
|
||||
- const { uploadToServer, releaseChannel } = params;
|
||||
-
|
||||
- crashReporter.start({
|
||||
- productName: 'Atom',
|
||||
- companyName: 'GitHub',
|
||||
- submitURL: 'https://atom.io/crash_reports',
|
||||
- uploadToServer,
|
||||
- extra: { platformRelease, arch, releaseChannel }
|
||||
- });
|
||||
};
|
@ -0,0 +1,11 @@
|
||||
--- src/main-process/atom-application.js.orig 2019-10-21 17:33:40 UTC
|
||||
+++ src/main-process/atom-application.js
|
||||
@@ -463,7 +463,7 @@ module.exports = class AtomApplication extends EventEm
|
||||
if (this.applicationMenu != null) {
|
||||
this.applicationMenu.enableWindowSpecificItems(false);
|
||||
}
|
||||
- if (['win32', 'linux'].includes(process.platform)) {
|
||||
+ if (['win32', 'linux', 'freebsd'].includes(process.platform)) {
|
||||
app.quit();
|
||||
return;
|
||||
}
|
11
editors/atom/files/patch-src_main-process_atom-window.js
Normal file
11
editors/atom/files/patch-src_main-process_atom-window.js
Normal file
@ -0,0 +1,11 @@
|
||||
--- src/main-process/atom-window.js.orig 2019-10-21 17:33:40 UTC
|
||||
+++ src/main-process/atom-window.js
|
||||
@@ -53,7 +53,7 @@ module.exports = class AtomWindow extends EventEmitter
|
||||
|
||||
// Don't set icon on Windows so the exe's ico will be used as window and
|
||||
// taskbar's icon. See https://github.com/atom/atom/issues/4811 for more.
|
||||
- if (process.platform === 'linux') options.icon = ICON_PATH;
|
||||
+ if (process.platform === 'linux' || process.platform === 'freebsd') options.icon = ICON_PATH;
|
||||
if (this.shouldAddCustomTitleBar()) options.titleBarStyle = 'hidden';
|
||||
if (this.shouldAddCustomInsetTitleBar())
|
||||
options.titleBarStyle = 'hiddenInset';
|
@ -0,0 +1,11 @@
|
||||
--- src/main-process/auto-update-manager.js.orig 2019-12-13 19:07:42 UTC
|
||||
+++ src/main-process/auto-update-manager.js
|
||||
@@ -101,7 +101,7 @@ module.exports = class AutoUpdateManager extends Event
|
||||
this.setState(UnsupportedState);
|
||||
}
|
||||
break;
|
||||
- case 'linux':
|
||||
+ case 'linux': case 'freebsd':
|
||||
this.setState(UnsupportedState);
|
||||
}
|
||||
}
|
29
editors/atom/files/patch-src_text-editor-component.js
Normal file
29
editors/atom/files/patch-src_text-editor-component.js
Normal file
@ -0,0 +1,29 @@
|
||||
--- src/text-editor-component.js.orig 2019-10-21 17:33:40 UTC
|
||||
+++ src/text-editor-component.js
|
||||
@@ -1809,7 +1809,7 @@ module.exports = class TextEditorComponent {
|
||||
// the paste event. And since we don't use the `paste` event for any
|
||||
// behavior in Atom, we can no-op the event to eliminate this issue.
|
||||
// See https://github.com/atom/atom/pull/15183#issue-248432413.
|
||||
- if (this.getPlatform() === 'linux') event.preventDefault();
|
||||
+ if (this.getPlatform() === 'linux' || this.getPlatform() === 'freebsd') event.preventDefault();
|
||||
}
|
||||
|
||||
didTextInput(event) {
|
||||
@@ -1973,7 +1973,7 @@ module.exports = class TextEditorComponent {
|
||||
// On Linux, pasting happens on middle click. A textInput event with the
|
||||
// contents of the selection clipboard will be dispatched by the browser
|
||||
// automatically on mouseup.
|
||||
- if (platform === 'linux' && this.isInputEnabled())
|
||||
+ if ((platform === 'linux' || platform === 'freebsd') && this.isInputEnabled())
|
||||
model.insertText(clipboard.readText('selection'));
|
||||
return;
|
||||
}
|
||||
@@ -2843,7 +2843,7 @@ module.exports = class TextEditorComponent {
|
||||
didChangeSelectionRange() {
|
||||
const { model } = this.props;
|
||||
|
||||
- if (this.getPlatform() === 'linux') {
|
||||
+ if (this.getPlatform() === 'linux' || this.getPlatform() === 'freebsd') {
|
||||
if (this.selectionClipboardImmediateId) {
|
||||
clearImmediate(this.selectionClipboardImmediateId);
|
||||
}
|
11
editors/atom/files/patch-src_update-process-env.js
Normal file
11
editors/atom/files/patch-src_update-process-env.js
Normal file
@ -0,0 +1,11 @@
|
||||
--- src/update-process-env.js.orig 2019-10-21 17:33:40 UTC
|
||||
+++ src/update-process-env.js
|
||||
@@ -8,7 +8,7 @@ const ENVIRONMENT_VARIABLES_TO_PRESERVE = new Set([
|
||||
'ATOM_DISABLE_SHELLING_OUT_FOR_ENVIRONMENT'
|
||||
]);
|
||||
|
||||
-const PLATFORMS_KNOWN_TO_WORK = new Set(['darwin', 'linux']);
|
||||
+const PLATFORMS_KNOWN_TO_WORK = new Set(['darwin', 'linux', 'freebsd']);
|
||||
|
||||
async function updateProcessEnv(launchEnv) {
|
||||
let envToAssign;
|
11
editors/atom/files/patch-src_window-event-handler.js
Normal file
11
editors/atom/files/patch-src_window-event-handler.js
Normal file
@ -0,0 +1,11 @@
|
||||
--- src/window-event-handler.js.orig 2019-10-21 17:33:40 UTC
|
||||
+++ src/window-event-handler.js
|
||||
@@ -44,7 +44,7 @@ module.exports = class WindowEventHandler {
|
||||
})
|
||||
);
|
||||
|
||||
- if (['win32', 'linux'].includes(process.platform)) {
|
||||
+ if (['win32', 'linux', 'freebsd'].includes(process.platform)) {
|
||||
this.subscriptions.add(
|
||||
this.atomEnvironment.commands.add(this.window, {
|
||||
'window:toggle-menu-bar': this.handleWindowToggleMenuBar
|
@ -0,0 +1,11 @@
|
||||
--- script/node_modules/electron-packager/ignore.js.orig 2019-12-27 05:37:51 UTC
|
||||
+++ script/node_modules/electron-packager/ignore.js
|
||||
@@ -19,7 +19,7 @@ function generateIgnores (opts) {
|
||||
} else {
|
||||
opts.ignore = [].concat(DEFAULT_IGNORES)
|
||||
}
|
||||
- if (process.platform === 'linux') {
|
||||
+ if (process.platform === 'linux' || process.platform === 'freebsd') {
|
||||
opts.ignore.push(common.baseTempDir(opts))
|
||||
}
|
||||
|
@ -0,0 +1,22 @@
|
||||
--- script/node_modules/electron-packager/targets.js.orig 1985-10-26 08:15:00 UTC
|
||||
+++ script/node_modules/electron-packager/targets.js
|
||||
@@ -5,9 +5,10 @@ const downloadArch = require('electron-download/lib/ar
|
||||
const semver = require('semver')
|
||||
|
||||
const officialArchs = ['ia32', 'x64', 'armv7l', 'arm64', 'mips64el']
|
||||
-const officialPlatforms = ['darwin', 'linux', 'mas', 'win32']
|
||||
+const officialPlatforms = ['darwin', 'freebsd', 'linux', 'mas', 'win32']
|
||||
const officialPlatformArchCombos = {
|
||||
darwin: ['x64'],
|
||||
+ freebsd: ['x64'],
|
||||
linux: ['ia32', 'x64', 'armv7l', 'arm64', 'mips64el'],
|
||||
mas: ['x64'],
|
||||
win32: ['ia32', 'x64']
|
||||
@@ -21,6 +22,7 @@ const linuxArchBuildVersions = {
|
||||
// Maps to module filename for each platform (lazy-required if used)
|
||||
const osModules = {
|
||||
darwin: './mac',
|
||||
+ freebsd: './linux',
|
||||
linux: './linux',
|
||||
mas: './mac', // map to darwin
|
||||
win32: './win32'
|
@ -0,0 +1,11 @@
|
||||
--- script/node_modules/os-homedir/index.js.orig 2019-12-27 05:38:53 UTC
|
||||
+++ script/node_modules/os-homedir/index.js
|
||||
@@ -14,7 +14,7 @@ function homedir() {
|
||||
return home || (user ? '/Users/' + user : null);
|
||||
}
|
||||
|
||||
- if (process.platform === 'linux') {
|
||||
+ if (process.platform === 'linux' || process.platform === 'freebsd') {
|
||||
return home || (process.getuid() === 0 ? '/root' : (user ? '/home/' + user : null));
|
||||
}
|
||||
|
@ -0,0 +1,29 @@
|
||||
--- script/node_modules/passwd-user/index.js.orig 2019-12-27 05:40:00 UTC
|
||||
+++ script/node_modules/passwd-user/index.js
|
||||
@@ -53,7 +53,7 @@ function extractLinux(line) {
|
||||
}
|
||||
|
||||
function getUser(str, username) {
|
||||
- const extract = process.platform === 'linux' ? extractLinux : extractDarwin;
|
||||
+ const extract = (process.platform === 'linux' || process.platform === 'freebsd') ? extractLinux : extractDarwin;
|
||||
const lines = str.split('\n');
|
||||
const l = lines.length;
|
||||
let i = 0;
|
||||
@@ -76,7 +76,7 @@ module.exports = username => {
|
||||
username = process.getuid();
|
||||
}
|
||||
|
||||
- if (process.platform === 'linux') {
|
||||
+ if (process.platform === 'linux' || process.platform === 'freebsd') {
|
||||
return pify(fs.readFile)('/etc/passwd', 'utf8')
|
||||
.then(passwd => getUser(passwd, username));
|
||||
}
|
||||
@@ -98,7 +98,7 @@ module.exports.sync = username => {
|
||||
username = process.getuid();
|
||||
}
|
||||
|
||||
- if (process.platform === 'linux') {
|
||||
+ if (process.platform === 'linux' || process.platform === 'freebsd') {
|
||||
return getUser(fs.readFileSync('/etc/passwd', 'utf8'), username);
|
||||
}
|
||||
|
@ -0,0 +1,11 @@
|
||||
--- script/node_modules/user-home/index.js.orig 2019-12-27 05:43:04 UTC
|
||||
+++ script/node_modules/user-home/index.js
|
||||
@@ -7,7 +7,7 @@ if (process.platform === 'win32') {
|
||||
module.exports = env.USERPROFILE || env.HOMEDRIVE + env.HOMEPATH || home || null;
|
||||
} else if (process.platform === 'darwin') {
|
||||
module.exports = home || (user ? '/Users/' + user : null) || null;
|
||||
-} else if (process.platform === 'linux') {
|
||||
+} else if (process.platform === 'linux' || process.platform === 'freebsd') {
|
||||
module.exports = home ||
|
||||
(user ? (process.getuid() === 0 ? '/root' : '/home/' + user) : null) || null;
|
||||
} else {
|
6
editors/atom/pkg-descr
Normal file
6
editors/atom/pkg-descr
Normal file
@ -0,0 +1,6 @@
|
||||
Atom is a hackable text editor for the 21st century, built on
|
||||
Electron, and based on everything we love about our favorite
|
||||
editors. We designed it to be deeply customizable, but still
|
||||
approachable using the default configuration.
|
||||
|
||||
WWW: https://atom.io/
|
7653
editors/atom/pkg-plist
Normal file
7653
editors/atom/pkg-plist
Normal file
File diff suppressed because it is too large
Load Diff
Loading…
Reference in New Issue
Block a user