mirror of
https://github.com/ckaczor/azuredatastudio.git
synced 2026-02-16 18:46:40 -05:00
Refresh master with initial release/0.24 snapshot (#332)
* Initial port of release/0.24 source code * Fix additional headers * Fix a typo in launch.json
This commit is contained in:
@@ -39,5 +39,22 @@ step "Build minified" \
|
||||
step "Run unit tests" \
|
||||
./scripts/test.sh --build --reporter dot
|
||||
|
||||
# function smoketest {
|
||||
# id -u testuser &>/dev/null || (useradd -m testuser; chpasswd <<< testuser:testpassword)
|
||||
# sudo -i -u testuser -- sh -c 'git config --global user.name "VS Code Agent" && git config --global user.email "monacotools@microsoft.com"'
|
||||
|
||||
# ARTIFACTS="$AGENT_BUILDDIRECTORY/smoketest-artifacts"
|
||||
# rm -rf $ARTIFACTS
|
||||
# mkdir -p $ARTIFACTS
|
||||
# chown -R testuser $ARTIFACTS
|
||||
|
||||
# ps -o pid= -u testuser | xargs sudo kill -9
|
||||
# DISPLAY=:10 sudo -i -u testuser -- sh -c "cd $BUILD_SOURCESDIRECTORY/test/smoke && ./node_modules/.bin/mocha --build $AGENT_BUILDDIRECTORY/VSCode-linux-$ARCH --log $ARTIFACTS"
|
||||
# # DISPLAY=:10 sudo -i -u testuser -- sh -c "cd /vso/work/1/s/test/smoke && ./node_modules/.bin/mocha --build /vso/work/1/VSCode-linux-ia32"
|
||||
# }
|
||||
|
||||
# step "Run smoke test" \
|
||||
# smoketest
|
||||
|
||||
step "Publish release" \
|
||||
./build/tfs/linux/release.sh
|
||||
|
||||
@@ -40,6 +40,9 @@ ADD xvfb.init /etc/init.d/xvfb
|
||||
RUN chmod +x /etc/init.d/xvfb
|
||||
RUN update-rc.d xvfb defaults
|
||||
|
||||
# dbus
|
||||
RUN ln -sf /bin/dbus-daemon /usr/bin/dbus-daemon
|
||||
|
||||
# nvm
|
||||
ENV NVM_DIR /usr/local/nvm
|
||||
RUN curl https://raw.githubusercontent.com/creationix/nvm/v0.33.2/install.sh | bash
|
||||
@@ -47,4 +50,4 @@ RUN curl https://raw.githubusercontent.com/creationix/nvm/v0.33.2/install.sh | b
|
||||
# for libsecret
|
||||
ENV PKG_CONFIG_PATH /usr/lib/i386-linux-gnu/pkgconfig
|
||||
|
||||
CMD (service xvfb start; export DISPLAY=:10; ./start.sh)
|
||||
CMD (service xvfb start; service dbus start; export DISPLAY=:10; ./start.sh)
|
||||
@@ -9,6 +9,9 @@ step "Build Debian package" \
|
||||
step "Build RPM package" \
|
||||
npm run gulp -- "vscode-linux-$ARCH-build-rpm"
|
||||
|
||||
# step "Build snap package" \
|
||||
# npm run gulp -- "vscode-linux-$ARCH-build-snap"
|
||||
|
||||
(cd $BUILD_SOURCESDIRECTORY/build/tfs/common && \
|
||||
step "Install build dependencies" \
|
||||
npm install --unsafe-perm)
|
||||
@@ -49,6 +52,9 @@ RPM_PATH="$REPO/.build/linux/rpm/$RPM_ARCH/$RPM_FILENAME"
|
||||
step "Publish RPM package" \
|
||||
node build/tfs/common/publish.js $VSCODE_QUALITY $PLATFORM_RPM package $RPM_FILENAME $VERSION true $RPM_PATH
|
||||
|
||||
# SNAP_FILENAME="$(ls $REPO/.build/linux/snap/$ARCH/ | grep .snap)"
|
||||
# SNAP_PATH="$REPO/.build/linux/snap/$ARCH/$SNAP_FILENAME"
|
||||
|
||||
if [ -z "$VSCODE_QUALITY" ]; then
|
||||
echo "VSCODE_QUALITY is not set, skipping repo package publish"
|
||||
else
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
#!/bin/bash -e
|
||||
# This is a VERY basic script for Create/Delete operations on repos and packages
|
||||
#
|
||||
#
|
||||
cmd=$1
|
||||
urls=urls.txt
|
||||
defaultPackageFile=new_package.json
|
||||
@@ -53,7 +53,7 @@ function ParseConfigFile {
|
||||
fi
|
||||
BailIfFileMissing "$configFile"
|
||||
secretContents=$(cat "$configFile")
|
||||
|
||||
|
||||
server=$(ParseFromJson .server)
|
||||
protocol=$(ParseFromJson .protocol)
|
||||
port=$(ParseFromJson .port)
|
||||
@@ -135,14 +135,14 @@ function AddPackageByUrl
|
||||
rm -f $tmpFile $tmpOut
|
||||
Bail "File is not a valid deb/rpm package $url"
|
||||
fi
|
||||
|
||||
|
||||
rm -f $tmpFile $tmpOut
|
||||
if [ -z "$pkgName" ]; then
|
||||
Bail "Unable to parse package name for $url"
|
||||
elif [ -z "$pkgVer" ]; then
|
||||
Bail "Unable to parse package version number for $url"
|
||||
fi
|
||||
|
||||
|
||||
# Create Package .json file
|
||||
escapedUrl=$(echo "$url" | sed 's/\//\\\//g' | sed 's/\&/\\\&/g')
|
||||
cp $defaultPackageFile.template $defaultPackageFile
|
||||
@@ -153,7 +153,7 @@ function AddPackageByUrl
|
||||
# Perform Upload
|
||||
AddPackage $defaultPackageFile
|
||||
# Cleanup
|
||||
rm -f $defaultPackageFile
|
||||
rm -f $defaultPackageFile
|
||||
}
|
||||
|
||||
# Upload multiple packages by reading urls line-by-line from the specified file
|
||||
|
||||
@@ -1,46 +0,0 @@
|
||||
#!/bin/bash
|
||||
set -e
|
||||
|
||||
. ./build/tfs/common/node.sh
|
||||
. ./scripts/env.sh
|
||||
. ./build/tfs/common/common.sh
|
||||
|
||||
export ARCH="$1"
|
||||
export VSCODE_MIXIN_PASSWORD="$2"
|
||||
VSO_PAT="$3"
|
||||
|
||||
echo "machine monacotools.visualstudio.com password $VSO_PAT" > ~/.netrc
|
||||
|
||||
step "Install dependencies" \
|
||||
npm install --arch=$ARCH --unsafe-perm
|
||||
|
||||
step "Mix in repository from vscode-distro" \
|
||||
npm run gulp -- mixin
|
||||
|
||||
step "Get Electron" \
|
||||
npm run gulp -- "electron-$ARCH"
|
||||
|
||||
step "Install distro dependencies" \
|
||||
node build/tfs/common/installDistro.js --arch=$ARCH
|
||||
|
||||
step "Build minified" \
|
||||
npm run gulp -- "vscode-linux-$ARCH-min"
|
||||
|
||||
function configureEnvironment {
|
||||
id -u testuser &>/dev/null || (useradd -m testuser; chpasswd <<< testuser:testpassword)
|
||||
sudo -i -u testuser git config --global user.name "VS Code Agent"
|
||||
sudo -i -u testuser git config --global user.email "monacotools@microsoft.com"
|
||||
chown -R testuser $AGENT_BUILDDIRECTORY
|
||||
}
|
||||
|
||||
function runTest {
|
||||
pushd test/smoke
|
||||
npm install
|
||||
sudo -u testuser -H xvfb-run -a -s "-screen 0 1024x768x8" npm test -- --latest "$AGENT_BUILDDIRECTORY/VSCode-linux-ia32/code-insiders"
|
||||
popd
|
||||
}
|
||||
|
||||
step "Configure environment" configureEnvironment
|
||||
|
||||
step "Run smoke test" runTest
|
||||
|
||||
@@ -36,8 +36,11 @@ ADD xvfb.init /etc/init.d/xvfb
|
||||
RUN chmod +x /etc/init.d/xvfb
|
||||
RUN update-rc.d xvfb defaults
|
||||
|
||||
# dbus
|
||||
RUN ln -sf /bin/dbus-daemon /usr/bin/dbus-daemon
|
||||
|
||||
# nvm
|
||||
ENV NVM_DIR /usr/local/nvm
|
||||
RUN curl https://raw.githubusercontent.com/creationix/nvm/v0.33.2/install.sh | bash
|
||||
|
||||
CMD (service xvfb start; export DISPLAY=:10; ./start.sh)
|
||||
CMD (service xvfb start; service dbus start; export DISPLAY=:10; ./start.sh)
|
||||
Reference in New Issue
Block a user