mirror of
https://github.com/balena-io/balena-cli.git
synced 2024-12-19 05:37:51 +00:00
build/deploy/push: Remove deprecated '--convert-eol' option
Change-type: major
This commit is contained in:
parent
176d731f9e
commit
f12f2b79ef
@ -3028,10 +3028,6 @@ Disable project validation check of 'docker-compose.yml' file in parent folder
|
|||||||
|
|
||||||
Path to a YAML or JSON file with passwords for a private Docker registry
|
Path to a YAML or JSON file with passwords for a private Docker registry
|
||||||
|
|
||||||
#### -l, --convert-eol
|
|
||||||
|
|
||||||
No-op and deprecated since balena CLI v12.0.0
|
|
||||||
|
|
||||||
#### --noconvert-eol
|
#### --noconvert-eol
|
||||||
|
|
||||||
Don't convert line endings from CRLF (Windows format) to LF (Unix format).
|
Don't convert line endings from CRLF (Windows format) to LF (Unix format).
|
||||||
@ -3256,10 +3252,6 @@ Disable project validation check of 'docker-compose.yml' file in parent folder
|
|||||||
|
|
||||||
Path to a YAML or JSON file with passwords for a private Docker registry
|
Path to a YAML or JSON file with passwords for a private Docker registry
|
||||||
|
|
||||||
#### -l, --convert-eol
|
|
||||||
|
|
||||||
No-op and deprecated since balena CLI v12.0.0
|
|
||||||
|
|
||||||
#### --noconvert-eol
|
#### --noconvert-eol
|
||||||
|
|
||||||
Don't convert line endings from CRLF (Windows format) to LF (Unix format).
|
Don't convert line endings from CRLF (Windows format) to LF (Unix format).
|
||||||
|
@ -22,7 +22,6 @@ import { getBalenaSdk, stripIndent } from '../utils/lazy';
|
|||||||
import { dockerignoreHelp, registrySecretsHelp } from '../utils/messages';
|
import { dockerignoreHelp, registrySecretsHelp } from '../utils/messages';
|
||||||
import type { BalenaSDK } from 'balena-sdk';
|
import type { BalenaSDK } from 'balena-sdk';
|
||||||
import { ExpectedError, instanceOf } from '../errors';
|
import { ExpectedError, instanceOf } from '../errors';
|
||||||
import { isV13 } from '../utils/version';
|
|
||||||
import { RegistrySecrets } from 'resin-multibuild';
|
import { RegistrySecrets } from 'resin-multibuild';
|
||||||
import { lowercaseIfSlug } from '../utils/normalization';
|
import { lowercaseIfSlug } from '../utils/normalization';
|
||||||
import {
|
import {
|
||||||
@ -52,7 +51,6 @@ interface FlagsDef {
|
|||||||
service?: string[];
|
service?: string[];
|
||||||
system: boolean;
|
system: boolean;
|
||||||
env?: string[];
|
env?: string[];
|
||||||
'convert-eol'?: boolean;
|
|
||||||
'noconvert-eol': boolean;
|
'noconvert-eol': boolean;
|
||||||
'multi-dockerignore': boolean;
|
'multi-dockerignore': boolean;
|
||||||
'release-tag'?: string[];
|
'release-tag'?: string[];
|
||||||
@ -216,16 +214,6 @@ export default class PushCmd extends Command {
|
|||||||
`,
|
`,
|
||||||
multiple: true,
|
multiple: true,
|
||||||
}),
|
}),
|
||||||
...(isV13()
|
|
||||||
? {}
|
|
||||||
: {
|
|
||||||
'convert-eol': flags.boolean({
|
|
||||||
description: 'No-op and deprecated since balena CLI v12.0.0',
|
|
||||||
char: 'l',
|
|
||||||
hidden: true,
|
|
||||||
default: false,
|
|
||||||
}),
|
|
||||||
}),
|
|
||||||
'noconvert-eol': flags.boolean({
|
'noconvert-eol': flags.boolean({
|
||||||
description: `Don't convert line endings from CRLF (Windows format) to LF (Unix format).`,
|
description: `Don't convert line endings from CRLF (Windows format) to LF (Unix format).`,
|
||||||
default: false,
|
default: false,
|
||||||
|
1
lib/utils/compose-types.d.ts
vendored
1
lib/utils/compose-types.d.ts
vendored
@ -65,7 +65,6 @@ export interface ComposeCliFlags {
|
|||||||
'multi-dockerignore': boolean;
|
'multi-dockerignore': boolean;
|
||||||
'noparent-check': boolean;
|
'noparent-check': boolean;
|
||||||
'registry-secrets'?: RegistrySecrets;
|
'registry-secrets'?: RegistrySecrets;
|
||||||
'convert-eol': boolean;
|
|
||||||
'noconvert-eol': boolean;
|
'noconvert-eol': boolean;
|
||||||
projectName?: string;
|
projectName?: string;
|
||||||
}
|
}
|
||||||
|
@ -1673,10 +1673,6 @@ export const composeCliFlags: flags.Input<ComposeCliFlags> = {
|
|||||||
'Path to a YAML or JSON file with passwords for a private Docker registry',
|
'Path to a YAML or JSON file with passwords for a private Docker registry',
|
||||||
char: 'R',
|
char: 'R',
|
||||||
}),
|
}),
|
||||||
'convert-eol': flags.boolean({
|
|
||||||
description: 'No-op and deprecated since balena CLI v12.0.0',
|
|
||||||
char: 'l',
|
|
||||||
}),
|
|
||||||
'noconvert-eol': flags.boolean({
|
'noconvert-eol': flags.boolean({
|
||||||
description:
|
description:
|
||||||
"Don't convert line endings from CRLF (Windows format) to LF (Unix format).",
|
"Don't convert line endings from CRLF (Windows format) to LF (Unix format).",
|
||||||
|
@ -126,16 +126,9 @@ describe('balena build', function () {
|
|||||||
];
|
];
|
||||||
if (isWindows) {
|
if (isWindows) {
|
||||||
const fname = path.join(projectPath, 'src', 'windows-crlf.sh');
|
const fname = path.join(projectPath, 'src', 'windows-crlf.sh');
|
||||||
if (isWindows) {
|
|
||||||
expectedResponseLines.push(
|
expectedResponseLines.push(
|
||||||
`[Info] Converting line endings CRLF -> LF for file: ${fname}`,
|
`[Info] Converting line endings CRLF -> LF for file: ${fname}`,
|
||||||
);
|
);
|
||||||
} else {
|
|
||||||
expectedResponseLines.push(
|
|
||||||
`[Warn] CRLF (Windows) line endings detected in file: ${fname}`,
|
|
||||||
'[Warn] Windows-format line endings were detected in some files. Consider using the `--convert-eol` option.',
|
|
||||||
);
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
docker.expectGetInfo({});
|
docker.expectGetInfo({});
|
||||||
docker.expectGetManifestBusybox();
|
docker.expectGetManifestBusybox();
|
||||||
@ -189,16 +182,9 @@ describe('balena build', function () {
|
|||||||
];
|
];
|
||||||
if (isWindows) {
|
if (isWindows) {
|
||||||
const fname = path.join(projectPath, 'src', 'windows-crlf.sh');
|
const fname = path.join(projectPath, 'src', 'windows-crlf.sh');
|
||||||
if (isWindows) {
|
|
||||||
expectedResponseLines.push(
|
expectedResponseLines.push(
|
||||||
`[Info] Converting line endings CRLF -> LF for file: ${fname}`,
|
`[Info] Converting line endings CRLF -> LF for file: ${fname}`,
|
||||||
);
|
);
|
||||||
} else {
|
|
||||||
expectedResponseLines.push(
|
|
||||||
`[Warn] CRLF (Windows) line endings detected in file: ${fname}`,
|
|
||||||
'[Warn] Windows-format line endings were detected in some files. Consider using the `--convert-eol` option.',
|
|
||||||
);
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
docker.expectGetInfo({});
|
docker.expectGetInfo({});
|
||||||
docker.expectGetManifestBusybox();
|
docker.expectGetManifestBusybox();
|
||||||
@ -312,7 +298,7 @@ describe('balena build', function () {
|
|||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
it('should create the expected tar stream (single container, --[no]convert-eol, --multi-dockerignore)', async () => {
|
it('should create the expected tar stream (single container, --noconvert-eol, --multi-dockerignore)', async () => {
|
||||||
const projectPath = path.join(projectsPath, 'no-docker-compose', 'basic');
|
const projectPath = path.join(projectsPath, 'no-docker-compose', 'basic');
|
||||||
const expectedFiles: ExpectedTarStreamFiles = {
|
const expectedFiles: ExpectedTarStreamFiles = {
|
||||||
'src/.dockerignore': { fileSize: 16, type: 'file' },
|
'src/.dockerignore': { fileSize: 16, type: 'file' },
|
||||||
@ -443,7 +429,7 @@ describe('balena build', function () {
|
|||||||
docker.expectGetManifestNucAlpine();
|
docker.expectGetManifestNucAlpine();
|
||||||
docker.expectGetManifestBusybox();
|
docker.expectGetManifestBusybox();
|
||||||
await testDockerBuildStream({
|
await testDockerBuildStream({
|
||||||
commandLine: `build ${projectPath} --deviceType nuc --arch amd64 --convert-eol -B COMPOSE_ARG=A -B barg=b --cache-from my/img1,my/img2`,
|
commandLine: `build ${projectPath} --deviceType nuc --arch amd64 -B COMPOSE_ARG=A -B barg=b --cache-from my/img1,my/img2`,
|
||||||
dockerMock: docker,
|
dockerMock: docker,
|
||||||
expectedFilesByService,
|
expectedFilesByService,
|
||||||
expectedQueryParamsByService,
|
expectedQueryParamsByService,
|
||||||
@ -526,7 +512,7 @@ describe('balena build', function () {
|
|||||||
docker.expectGetManifestNucAlpine();
|
docker.expectGetManifestNucAlpine();
|
||||||
|
|
||||||
await testDockerBuildStream({
|
await testDockerBuildStream({
|
||||||
commandLine: `build ${projectPath} --deviceType nuc --arch amd64 --convert-eol -m`,
|
commandLine: `build ${projectPath} --deviceType nuc --arch amd64 -m`,
|
||||||
dockerMock: docker,
|
dockerMock: docker,
|
||||||
expectedFilesByService,
|
expectedFilesByService,
|
||||||
expectedQueryParamsByService,
|
expectedQueryParamsByService,
|
||||||
@ -611,7 +597,7 @@ describe('balena build', function () {
|
|||||||
docker.expectGetManifestNucAlpine();
|
docker.expectGetManifestNucAlpine();
|
||||||
|
|
||||||
await testDockerBuildStream({
|
await testDockerBuildStream({
|
||||||
commandLine: `build ${projectPath} --deviceType nuc --arch amd64 --convert-eol -m --tag ${tag} --projectName ${projectName}`,
|
commandLine: `build ${projectPath} --deviceType nuc --arch amd64 -m --tag ${tag} --projectName ${projectName}`,
|
||||||
dockerMock: docker,
|
dockerMock: docker,
|
||||||
expectedFilesByService,
|
expectedFilesByService,
|
||||||
expectedQueryParamsByService,
|
expectedQueryParamsByService,
|
||||||
|
@ -190,7 +190,7 @@ describe('balena push', function () {
|
|||||||
});
|
});
|
||||||
});
|
});
|
||||||
|
|
||||||
it('should create the expected tar stream (single container, --[no]convert-eol)', async () => {
|
it('should create the expected tar stream (single container, --noconvert-eol)', async () => {
|
||||||
const projectPath = path.join(projectsPath, 'no-docker-compose', 'basic');
|
const projectPath = path.join(projectsPath, 'no-docker-compose', 'basic');
|
||||||
const expectedFiles: ExpectedTarStreamFiles = {
|
const expectedFiles: ExpectedTarStreamFiles = {
|
||||||
'src/.dockerignore': { fileSize: 16, type: 'file' },
|
'src/.dockerignore': { fileSize: 16, type: 'file' },
|
||||||
|
Loading…
Reference in New Issue
Block a user