Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Refactoring] Build Script in terms of Duplicate Code Removal #281

Merged
merged 1 commit into from Mar 5, 2021

Conversation

tiokim
Copy link
Contributor

@tiokim tiokim commented Mar 3, 2021

Signed-off-by: Taewan Kim t25.kim@samsung.com

Description

Refactor build.sh file in terms of duplicate code removal in order to reduce LoC

  • set_option() set build options, such as BUILD_TAGS, ARCH, CC, etc., in one function.
  • Duplicated/unnecessary code has been removed

Fixes #278

Type of change

  • Code cleanup/refactoring

How Has This Been Tested?

Build through ./build.sh with several options.
Refer to the build test from GitHub Actions

Test Configuration:

  • Firmware version: Ubuntu 16.04
  • Hardware: x86-64
  • Edge Orchestration Release: Coconut

Checklist:

  • My code follows the style guidelines of this project
  • I have performed a self-review of my own code
  • I have commented my code, particularly in hard-to-understand areas
  • I have made corresponding changes to the documentation
  • My changes generate no new warnings
  • I have added tests that prove my fix is effective or that my feature works
  • New and existing unit tests pass locally with my changes

… reduce LoC

- set_option() set build options, such as BUILD_TAGS, ARCH, CC, etc., in one function.
- Duplicated/redundant code has been removed

Signed-off-by: Taewan Kim <t25.kim@samsung.com>
@tiokim tiokim added the refactoring Any tasks and issues w.r.t. the code refactoring label Mar 3, 2021
@tiokim tiokim added this to In progress in Refactoring via automation Mar 3, 2021
@sonarcloud
Copy link

sonarcloud bot commented Mar 3, 2021

Kudos, SonarCloud Quality Gate passed!

Bug A 0 Bugs
Vulnerability A 0 Vulnerabilities
Security Hotspot A 0 Security Hotspots
Code Smell A 0 Code Smells

No Coverage information No Coverage information
No Duplication information No Duplication information

Refactoring automation moved this from In progress to Reviewer approved Mar 3, 2021
Copy link
Contributor

@tdrozdovsky tdrozdovsky left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM! I have tested the edge-orchestration on the Raspberry Pi 3 cluster in secure and normal modes. Everything works well! Thanks @t25kim for the optimization!

Copy link
Contributor

@suresh-lc suresh-lc left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM. Making build script simple by removing redundancies is good.

Copy link
Contributor

@MoonkiHong MoonkiHong left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM.

@MoonkiHong MoonkiHong merged commit 4b35082 into lf-edge:master Mar 5, 2021
Refactoring automation moved this from Reviewer approved to Done Mar 5, 2021
@tiokim tiokim deleted the ref_buildsh branch May 16, 2021 23:35
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
refactoring Any tasks and issues w.r.t. the code refactoring
Projects
Development

Successfully merging this pull request may close these issues.

[Refactoring] Build script
4 participants