Turn on Share Link in nightly builds (#5153)
* WIP: Turn on link sharing in released apps with electron-builder Fixes #5136 * Add import.meta.env defaults * A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores) * Add convenience scripts for windows development; fix protocol name for electron; enable share cmd * A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores) * Force release builds * A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores) * Trigger CI * Fix lint * A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores) * CSC_FOR_PULL_REQUEST: true for release build testing * A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores) * Adding :// * A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores) * Back to debug builds * A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores) * Back to debug builds * WIP: origin * A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores) * To revert: Add logs and custom package version for easier testing * A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores) * More messing with env vars * A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores) * Messing with help from deep links docs * Removed alerts * Working on macos * A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores) * A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores) * A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores) * Working second window on windows. Cold start not yet working * A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores) * Handle windows cold start * A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores) * Clean up after macos testing * A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores) * Replace tron:package (Forge) with tronb📦dev (Builder) for e2e * Add new env var for web app link * tronb:vite:dev for e2e * Remove app.requestSingleInstanceLock() call * Fix unit test * A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores) * Revert snap changes * Only nightly at first * Remove test app * Update package.json * Update src/main.ts * Remove fetch:wasm:windows * Final line * Clean up * Back to test app for final test * Fix tsc * Back to https://app.dev.zoo.dev from vercel branch deploy --------- Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
This commit is contained in:
@ -1,11 +1,7 @@
|
||||
import { UnitLength_type } from '@kittycad/lib/dist/types/src/models'
|
||||
import {
|
||||
ASK_TO_OPEN_QUERY_PARAM,
|
||||
CREATE_FILE_URL_PARAM,
|
||||
PROD_APP_URL,
|
||||
} from './constants'
|
||||
import { ASK_TO_OPEN_QUERY_PARAM, CREATE_FILE_URL_PARAM } from './constants'
|
||||
import { stringToBase64 } from './base64'
|
||||
import { DEV, VITE_KC_API_BASE_URL } from 'env'
|
||||
import { VITE_KC_API_BASE_URL, VITE_KC_SITE_APP_URL } from 'env'
|
||||
import toast from 'react-hot-toast'
|
||||
import { err } from './trap'
|
||||
export interface FileLinkParams {
|
||||
@ -51,8 +47,7 @@ export async function copyFileShareLink(
|
||||
* open the URL in the desktop app.
|
||||
*/
|
||||
export function createCreateFileUrl({ code, name, units }: FileLinkParams) {
|
||||
// Use the dev server if we are in development mode
|
||||
let origin = DEV ? 'http://localhost:3000' : PROD_APP_URL
|
||||
let origin = VITE_KC_SITE_APP_URL
|
||||
const searchParams = new URLSearchParams({
|
||||
[CREATE_FILE_URL_PARAM]: String(true),
|
||||
name,
|
||||
|
Reference in New Issue
Block a user