JohnCoates/Aerial

View on GitHub

Showing 257 of 1,136 total issues

Similar blocks of code found in 17 locations. Consider refactoring.
Open

    @IBAction func visitDiscordClick(_ sender: Any) {
        let workspace = NSWorkspace.shared
        let url = URL(string: "https://discord.gg/TPuA5WG")!
        workspace.open(url)
    }
Severity: Major
Found in Resources/MainUI/Infos panels/HelpViewController.swift and 16 other locations - About 35 mins to fix
Resources/MainUI/First time setup/RecapViewController.swift on lines 24..28
Resources/MainUI/First time setup/RecapViewController.swift on lines 30..34
Resources/MainUI/First time setup/TimeSetupViewController.swift on lines 105..109
Resources/MainUI/First time setup/VideoFormatViewController.swift on lines 59..63
Resources/MainUI/Infos panels/CreditsViewController.swift on lines 21..25
Resources/MainUI/Infos panels/CreditsViewController.swift on lines 27..31
Resources/MainUI/Infos panels/CreditsViewController.swift on lines 33..37
Resources/MainUI/Infos panels/CreditsViewController.swift on lines 39..43
Resources/MainUI/Infos panels/HelpViewController.swift on lines 18..22
Resources/MainUI/Infos panels/HelpViewController.swift on lines 24..28
Resources/MainUI/Infos panels/HelpViewController.swift on lines 30..34
Resources/MainUI/Infos panels/InfoViewController.swift on lines 21..25
Resources/MainUI/Infos panels/InfoViewController.swift on lines 27..31
Resources/MainUI/Settings panels/AdvancedViewController.swift on lines 295..299
Resources/MainUI/Settings panels/AdvancedViewController.swift on lines 301..305
Resources/MainUI/Settings panels/SourcesViewController.swift on lines 116..120

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 47.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 17 locations. Consider refactoring.
Open

    @IBAction func donateButton(_ sender: Any) {
        let workspace = NSWorkspace.shared
        let url = URL(string: "https://ko-fi.com/A0A32385Y")!
        workspace.open(url)
    }
Severity: Major
Found in Resources/MainUI/Infos panels/InfoViewController.swift and 16 other locations - About 35 mins to fix
Resources/MainUI/First time setup/RecapViewController.swift on lines 24..28
Resources/MainUI/First time setup/RecapViewController.swift on lines 30..34
Resources/MainUI/First time setup/TimeSetupViewController.swift on lines 105..109
Resources/MainUI/First time setup/VideoFormatViewController.swift on lines 59..63
Resources/MainUI/Infos panels/CreditsViewController.swift on lines 21..25
Resources/MainUI/Infos panels/CreditsViewController.swift on lines 27..31
Resources/MainUI/Infos panels/CreditsViewController.swift on lines 33..37
Resources/MainUI/Infos panels/CreditsViewController.swift on lines 39..43
Resources/MainUI/Infos panels/HelpViewController.swift on lines 18..22
Resources/MainUI/Infos panels/HelpViewController.swift on lines 24..28
Resources/MainUI/Infos panels/HelpViewController.swift on lines 30..34
Resources/MainUI/Infos panels/HelpViewController.swift on lines 36..40
Resources/MainUI/Infos panels/InfoViewController.swift on lines 27..31
Resources/MainUI/Settings panels/AdvancedViewController.swift on lines 295..299
Resources/MainUI/Settings panels/AdvancedViewController.swift on lines 301..305
Resources/MainUI/Settings panels/SourcesViewController.swift on lines 116..120

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 47.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 3 locations. Consider refactoring.
Open

        nameLayer.string = ""
        (nameLayer.font, nameLayer.fontSize) = nameLayer.makeFont(name: PrefsInfo.music.fontName, size: PrefsInfo.music.fontSize)
Severity: Minor
Found in Aerial/Source/Views/Layers/Music/MusicLayer.swift and 2 other locations - About 35 mins to fix
Aerial/Source/Views/Layers/Music/MusicLayer.swift on lines 83..84
Aerial/Source/Views/Layers/Music/MusicLayer.swift on lines 88..89

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 47.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 3 locations. Consider refactoring.
Open

//
//  OverlaysViewController.swift
//  Aerial
//
//  Created by Guillaume Louel on 19/07/2020.
Severity: Minor
Found in Resources/MainUI/Settings panels/OverlaysViewController.swift and 2 other locations - About 35 mins to fix
Resources/MainUI/Settings panels/OverlaysViewController.swift on lines 1..232
Resources/MainUI/Settings panels/OverlaysViewController.swift on lines 1..232

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 47.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Identical blocks of code found in 2 locations. Consider refactoring.
Open

        var minX: CGFloat, minY: CGFloat, maxX: CGFloat, maxY: CGFloat, scaleFactor: CGFloat
Severity: Minor
Found in Aerial/Source/Views/PrefPanel/DisplayView.swift and 1 other location - About 35 mins to fix
Aerial/Source/Views/PrefPanel/DisplayView.swift on lines 88..88

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 47.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 17 locations. Consider refactoring.
Open

    @IBAction func moreInfoFormats(_ sender: Any) {
        let workspace = NSWorkspace.shared
        let url = URL(string: "https://github.com/JohnCoates/Aerial/blob/master/Documentation/HardwareDecoding.md")!
        workspace.open(url)
    }
Resources/MainUI/First time setup/RecapViewController.swift on lines 24..28
Resources/MainUI/First time setup/RecapViewController.swift on lines 30..34
Resources/MainUI/First time setup/TimeSetupViewController.swift on lines 105..109
Resources/MainUI/Infos panels/CreditsViewController.swift on lines 21..25
Resources/MainUI/Infos panels/CreditsViewController.swift on lines 27..31
Resources/MainUI/Infos panels/CreditsViewController.swift on lines 33..37
Resources/MainUI/Infos panels/CreditsViewController.swift on lines 39..43
Resources/MainUI/Infos panels/HelpViewController.swift on lines 18..22
Resources/MainUI/Infos panels/HelpViewController.swift on lines 24..28
Resources/MainUI/Infos panels/HelpViewController.swift on lines 30..34
Resources/MainUI/Infos panels/HelpViewController.swift on lines 36..40
Resources/MainUI/Infos panels/InfoViewController.swift on lines 21..25
Resources/MainUI/Infos panels/InfoViewController.swift on lines 27..31
Resources/MainUI/Settings panels/AdvancedViewController.swift on lines 295..299
Resources/MainUI/Settings panels/AdvancedViewController.swift on lines 301..305
Resources/MainUI/Settings panels/SourcesViewController.swift on lines 116..120

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 47.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 17 locations. Consider refactoring.
Open

    @IBAction func websiteButton(_ sender: Any) {
        let workspace = NSWorkspace.shared
        let url = URL(string: "https://aerialscreensaver.github.io")!
        workspace.open(url)
    }
Severity: Major
Found in Resources/MainUI/Infos panels/CreditsViewController.swift and 16 other locations - About 35 mins to fix
Resources/MainUI/First time setup/RecapViewController.swift on lines 24..28
Resources/MainUI/First time setup/RecapViewController.swift on lines 30..34
Resources/MainUI/First time setup/TimeSetupViewController.swift on lines 105..109
Resources/MainUI/First time setup/VideoFormatViewController.swift on lines 59..63
Resources/MainUI/Infos panels/CreditsViewController.swift on lines 21..25
Resources/MainUI/Infos panels/CreditsViewController.swift on lines 33..37
Resources/MainUI/Infos panels/CreditsViewController.swift on lines 39..43
Resources/MainUI/Infos panels/HelpViewController.swift on lines 18..22
Resources/MainUI/Infos panels/HelpViewController.swift on lines 24..28
Resources/MainUI/Infos panels/HelpViewController.swift on lines 30..34
Resources/MainUI/Infos panels/HelpViewController.swift on lines 36..40
Resources/MainUI/Infos panels/InfoViewController.swift on lines 21..25
Resources/MainUI/Infos panels/InfoViewController.swift on lines 27..31
Resources/MainUI/Settings panels/AdvancedViewController.swift on lines 295..299
Resources/MainUI/Settings panels/AdvancedViewController.swift on lines 301..305
Resources/MainUI/Settings panels/SourcesViewController.swift on lines 116..120

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 47.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 17 locations. Consider refactoring.
Open

    @IBAction func locationServicesClick(_ sender: Any) {
        let workspace = NSWorkspace.shared
        let url = URL(string: "https://github.com/JohnCoates/Aerial/blob/master/Documentation/Troubleshooting.md#issues-on-macos-1014-and-earlier")!
        workspace.open(url)
    }
Resources/MainUI/First time setup/RecapViewController.swift on lines 24..28
Resources/MainUI/First time setup/RecapViewController.swift on lines 30..34
Resources/MainUI/First time setup/VideoFormatViewController.swift on lines 59..63
Resources/MainUI/Infos panels/CreditsViewController.swift on lines 21..25
Resources/MainUI/Infos panels/CreditsViewController.swift on lines 27..31
Resources/MainUI/Infos panels/CreditsViewController.swift on lines 33..37
Resources/MainUI/Infos panels/CreditsViewController.swift on lines 39..43
Resources/MainUI/Infos panels/HelpViewController.swift on lines 18..22
Resources/MainUI/Infos panels/HelpViewController.swift on lines 24..28
Resources/MainUI/Infos panels/HelpViewController.swift on lines 30..34
Resources/MainUI/Infos panels/HelpViewController.swift on lines 36..40
Resources/MainUI/Infos panels/InfoViewController.swift on lines 21..25
Resources/MainUI/Infos panels/InfoViewController.swift on lines 27..31
Resources/MainUI/Settings panels/AdvancedViewController.swift on lines 295..299
Resources/MainUI/Settings panels/AdvancedViewController.swift on lines 301..305
Resources/MainUI/Settings panels/SourcesViewController.swift on lines 116..120

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 47.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 17 locations. Consider refactoring.
Open

    @IBAction func projectButton(_ sender: Any) {
        let workspace = NSWorkspace.shared
        let url = URL(string: "https://github.com/JohnCoates/Aerial")!
        workspace.open(url)
    }
Severity: Major
Found in Resources/MainUI/Infos panels/CreditsViewController.swift and 16 other locations - About 35 mins to fix
Resources/MainUI/First time setup/RecapViewController.swift on lines 24..28
Resources/MainUI/First time setup/RecapViewController.swift on lines 30..34
Resources/MainUI/First time setup/TimeSetupViewController.swift on lines 105..109
Resources/MainUI/First time setup/VideoFormatViewController.swift on lines 59..63
Resources/MainUI/Infos panels/CreditsViewController.swift on lines 21..25
Resources/MainUI/Infos panels/CreditsViewController.swift on lines 27..31
Resources/MainUI/Infos panels/CreditsViewController.swift on lines 39..43
Resources/MainUI/Infos panels/HelpViewController.swift on lines 18..22
Resources/MainUI/Infos panels/HelpViewController.swift on lines 24..28
Resources/MainUI/Infos panels/HelpViewController.swift on lines 30..34
Resources/MainUI/Infos panels/HelpViewController.swift on lines 36..40
Resources/MainUI/Infos panels/InfoViewController.swift on lines 21..25
Resources/MainUI/Infos panels/InfoViewController.swift on lines 27..31
Resources/MainUI/Settings panels/AdvancedViewController.swift on lines 295..299
Resources/MainUI/Settings panels/AdvancedViewController.swift on lines 301..305
Resources/MainUI/Settings panels/SourcesViewController.swift on lines 116..120

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 47.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 7 locations. Consider refactoring.
Open

        max.string = "\(String(format: "%.0f", tmax!))°"

        (max.font, max.fontSize) = max.makeFont(name: PrefsInfo.weather.fontName, size: size/4)
Severity: Major
Found in Aerial/Source/Views/Layers/Weather/ForecastLayer.swift and 6 other locations - About 35 mins to fix
Aerial/Source/Views/Layers/Weather/ForecastLayer.swift on lines 186..188
Aerial/Source/Views/Layers/Weather/ForecastLayer.swift on lines 197..199
Aerial/Source/Views/Layers/Weather/ForecastLayer.swift on lines 274..276
Aerial/Source/Views/Layers/Weather/ForecastLayer.swift on lines 285..287
Aerial/Source/Views/Layers/Weather/ForecastLayer.swift on lines 296..298
Aerial/Source/Views/Layers/Weather/ForecastLayer.swift on lines 415..416

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 47.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 17 locations. Consider refactoring.
Open

    @IBAction func faqButton(_ sender: Any) {
        let workspace = NSWorkspace.shared
        let url = URL(string: "https://aerialscreensaver.github.io/faq.html")!
        workspace.open(url)
    }
Severity: Major
Found in Resources/MainUI/Infos panels/HelpViewController.swift and 16 other locations - About 35 mins to fix
Resources/MainUI/First time setup/RecapViewController.swift on lines 24..28
Resources/MainUI/First time setup/RecapViewController.swift on lines 30..34
Resources/MainUI/First time setup/TimeSetupViewController.swift on lines 105..109
Resources/MainUI/First time setup/VideoFormatViewController.swift on lines 59..63
Resources/MainUI/Infos panels/CreditsViewController.swift on lines 21..25
Resources/MainUI/Infos panels/CreditsViewController.swift on lines 27..31
Resources/MainUI/Infos panels/CreditsViewController.swift on lines 33..37
Resources/MainUI/Infos panels/CreditsViewController.swift on lines 39..43
Resources/MainUI/Infos panels/HelpViewController.swift on lines 24..28
Resources/MainUI/Infos panels/HelpViewController.swift on lines 30..34
Resources/MainUI/Infos panels/HelpViewController.swift on lines 36..40
Resources/MainUI/Infos panels/InfoViewController.swift on lines 21..25
Resources/MainUI/Infos panels/InfoViewController.swift on lines 27..31
Resources/MainUI/Settings panels/AdvancedViewController.swift on lines 295..299
Resources/MainUI/Settings panels/AdvancedViewController.swift on lines 301..305
Resources/MainUI/Settings panels/SourcesViewController.swift on lines 116..120

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 47.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 17 locations. Consider refactoring.
Open

    @IBAction func dolbyVisionClick(_ sender: Any) {
        let workspace = NSWorkspace.shared
        let url = URL(string: "https://en.wikipedia.org/wiki/Dolby_Laboratories#Video_processing")!
        workspace.open(url)
    }
Severity: Major
Found in Resources/MainUI/Settings panels/AdvancedViewController.swift and 16 other locations - About 35 mins to fix
Resources/MainUI/First time setup/RecapViewController.swift on lines 24..28
Resources/MainUI/First time setup/RecapViewController.swift on lines 30..34
Resources/MainUI/First time setup/TimeSetupViewController.swift on lines 105..109
Resources/MainUI/First time setup/VideoFormatViewController.swift on lines 59..63
Resources/MainUI/Infos panels/CreditsViewController.swift on lines 21..25
Resources/MainUI/Infos panels/CreditsViewController.swift on lines 27..31
Resources/MainUI/Infos panels/CreditsViewController.swift on lines 33..37
Resources/MainUI/Infos panels/CreditsViewController.swift on lines 39..43
Resources/MainUI/Infos panels/HelpViewController.swift on lines 18..22
Resources/MainUI/Infos panels/HelpViewController.swift on lines 24..28
Resources/MainUI/Infos panels/HelpViewController.swift on lines 30..34
Resources/MainUI/Infos panels/HelpViewController.swift on lines 36..40
Resources/MainUI/Infos panels/InfoViewController.swift on lines 21..25
Resources/MainUI/Infos panels/InfoViewController.swift on lines 27..31
Resources/MainUI/Settings panels/AdvancedViewController.swift on lines 301..305
Resources/MainUI/Settings panels/SourcesViewController.swift on lines 116..120

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 47.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 7 locations. Consider refactoring.
Open

        humidity.string = "\(whumidity!)%"

        (humidity.font, humidity.fontSize) = humidity.makeFont(name: PrefsInfo.weather.fontName, size: size/4)
Severity: Major
Found in Aerial/Source/Views/Layers/Weather/ForecastLayer.swift and 6 other locations - About 35 mins to fix
Aerial/Source/Views/Layers/Weather/ForecastLayer.swift on lines 175..177
Aerial/Source/Views/Layers/Weather/ForecastLayer.swift on lines 186..188
Aerial/Source/Views/Layers/Weather/ForecastLayer.swift on lines 274..276
Aerial/Source/Views/Layers/Weather/ForecastLayer.swift on lines 285..287
Aerial/Source/Views/Layers/Weather/ForecastLayer.swift on lines 296..298
Aerial/Source/Views/Layers/Weather/ForecastLayer.swift on lines 415..416

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 47.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 3 locations. Consider refactoring.
Open

        artistLayer.string = ""
        (artistLayer.font, artistLayer.fontSize) = artistLayer.makeFont(name: PrefsInfo.music.fontName, size: PrefsInfo.music.fontSize)
Severity: Minor
Found in Aerial/Source/Views/Layers/Music/MusicLayer.swift and 2 other locations - About 35 mins to fix
Aerial/Source/Views/Layers/Music/MusicLayer.swift on lines 78..79
Aerial/Source/Views/Layers/Music/MusicLayer.swift on lines 88..89

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 47.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 17 locations. Consider refactoring.
Open

    @IBAction func iconWebsiteButton(_ sender: Any) {
        let workspace = NSWorkspace.shared
        let url = URL(string: "https://infernodesign.com")!
        workspace.open(url)
    }
Severity: Major
Found in Resources/MainUI/Infos panels/InfoViewController.swift and 16 other locations - About 35 mins to fix
Resources/MainUI/First time setup/RecapViewController.swift on lines 24..28
Resources/MainUI/First time setup/RecapViewController.swift on lines 30..34
Resources/MainUI/First time setup/TimeSetupViewController.swift on lines 105..109
Resources/MainUI/First time setup/VideoFormatViewController.swift on lines 59..63
Resources/MainUI/Infos panels/CreditsViewController.swift on lines 21..25
Resources/MainUI/Infos panels/CreditsViewController.swift on lines 27..31
Resources/MainUI/Infos panels/CreditsViewController.swift on lines 33..37
Resources/MainUI/Infos panels/CreditsViewController.swift on lines 39..43
Resources/MainUI/Infos panels/HelpViewController.swift on lines 18..22
Resources/MainUI/Infos panels/HelpViewController.swift on lines 24..28
Resources/MainUI/Infos panels/HelpViewController.swift on lines 30..34
Resources/MainUI/Infos panels/HelpViewController.swift on lines 36..40
Resources/MainUI/Infos panels/InfoViewController.swift on lines 21..25
Resources/MainUI/Settings panels/AdvancedViewController.swift on lines 295..299
Resources/MainUI/Settings panels/AdvancedViewController.swift on lines 301..305
Resources/MainUI/Settings panels/SourcesViewController.swift on lines 116..120

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 47.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 17 locations. Consider refactoring.
Open

    @IBAction func checkJoshHal(_ sender: Any) {
        let workspace = NSWorkspace.shared
        let url = URL(string: "https://www.jetsoncreative.com/aerial")!
        workspace.open(url)
    }
Severity: Major
Found in Resources/MainUI/First time setup/RecapViewController.swift and 16 other locations - About 35 mins to fix
Resources/MainUI/First time setup/RecapViewController.swift on lines 24..28
Resources/MainUI/First time setup/TimeSetupViewController.swift on lines 105..109
Resources/MainUI/First time setup/VideoFormatViewController.swift on lines 59..63
Resources/MainUI/Infos panels/CreditsViewController.swift on lines 21..25
Resources/MainUI/Infos panels/CreditsViewController.swift on lines 27..31
Resources/MainUI/Infos panels/CreditsViewController.swift on lines 33..37
Resources/MainUI/Infos panels/CreditsViewController.swift on lines 39..43
Resources/MainUI/Infos panels/HelpViewController.swift on lines 18..22
Resources/MainUI/Infos panels/HelpViewController.swift on lines 24..28
Resources/MainUI/Infos panels/HelpViewController.swift on lines 30..34
Resources/MainUI/Infos panels/HelpViewController.swift on lines 36..40
Resources/MainUI/Infos panels/InfoViewController.swift on lines 21..25
Resources/MainUI/Infos panels/InfoViewController.swift on lines 27..31
Resources/MainUI/Settings panels/AdvancedViewController.swift on lines 295..299
Resources/MainUI/Settings panels/AdvancedViewController.swift on lines 301..305
Resources/MainUI/Settings panels/SourcesViewController.swift on lines 116..120

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 47.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 7 locations. Consider refactoring.
Open

        humidity.string = "Humidity"
        (humidity.font, humidity.fontSize) = humidity.makeFont(name: PrefsInfo.weather.fontName, size: size/4)
Severity: Major
Found in Aerial/Source/Views/Layers/Weather/ForecastLayer.swift and 6 other locations - About 35 mins to fix
Aerial/Source/Views/Layers/Weather/ForecastLayer.swift on lines 175..177
Aerial/Source/Views/Layers/Weather/ForecastLayer.swift on lines 186..188
Aerial/Source/Views/Layers/Weather/ForecastLayer.swift on lines 197..199
Aerial/Source/Views/Layers/Weather/ForecastLayer.swift on lines 274..276
Aerial/Source/Views/Layers/Weather/ForecastLayer.swift on lines 285..287
Aerial/Source/Views/Layers/Weather/ForecastLayer.swift on lines 296..298

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 47.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 7 locations. Consider refactoring.
Open

        feelsLike.string = "\(String(format: "%.0f", hour.main!.feelsLike!))°"

        (feelsLike.font, feelsLike.fontSize) = feelsLike.makeFont(name: PrefsInfo.weather.fontName, size: size/4)
Severity: Major
Found in Aerial/Source/Views/Layers/Weather/ForecastLayer.swift and 6 other locations - About 35 mins to fix
Aerial/Source/Views/Layers/Weather/ForecastLayer.swift on lines 175..177
Aerial/Source/Views/Layers/Weather/ForecastLayer.swift on lines 186..188
Aerial/Source/Views/Layers/Weather/ForecastLayer.swift on lines 197..199
Aerial/Source/Views/Layers/Weather/ForecastLayer.swift on lines 274..276
Aerial/Source/Views/Layers/Weather/ForecastLayer.swift on lines 296..298
Aerial/Source/Views/Layers/Weather/ForecastLayer.swift on lines 415..416

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 47.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 17 locations. Consider refactoring.
Open

    @IBAction func issuesButton(_ sender: Any) {
        let workspace = NSWorkspace.shared
        let url = URL(string: "https://github.com/JohnCoates/Aerial/issues")!
        workspace.open(url)
    }
Severity: Major
Found in Resources/MainUI/Infos panels/HelpViewController.swift and 16 other locations - About 35 mins to fix
Resources/MainUI/First time setup/RecapViewController.swift on lines 24..28
Resources/MainUI/First time setup/RecapViewController.swift on lines 30..34
Resources/MainUI/First time setup/TimeSetupViewController.swift on lines 105..109
Resources/MainUI/First time setup/VideoFormatViewController.swift on lines 59..63
Resources/MainUI/Infos panels/CreditsViewController.swift on lines 21..25
Resources/MainUI/Infos panels/CreditsViewController.swift on lines 27..31
Resources/MainUI/Infos panels/CreditsViewController.swift on lines 33..37
Resources/MainUI/Infos panels/CreditsViewController.swift on lines 39..43
Resources/MainUI/Infos panels/HelpViewController.swift on lines 18..22
Resources/MainUI/Infos panels/HelpViewController.swift on lines 24..28
Resources/MainUI/Infos panels/HelpViewController.swift on lines 36..40
Resources/MainUI/Infos panels/InfoViewController.swift on lines 21..25
Resources/MainUI/Infos panels/InfoViewController.swift on lines 27..31
Resources/MainUI/Settings panels/AdvancedViewController.swift on lines 295..299
Resources/MainUI/Settings panels/AdvancedViewController.swift on lines 301..305
Resources/MainUI/Settings panels/SourcesViewController.swift on lines 116..120

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 47.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 17 locations. Consider refactoring.
Open

    @IBAction func projectPageClick(_ sender: Any) {
        let workspace = NSWorkspace.shared
        let url = URL(string: "https://github.com/JohnCoates/Aerial/blob/master/Documentation/HardwareDecoding.md")!
        workspace.open(url)
    }
Severity: Major
Found in Resources/MainUI/Settings panels/AdvancedViewController.swift and 16 other locations - About 35 mins to fix
Resources/MainUI/First time setup/RecapViewController.swift on lines 24..28
Resources/MainUI/First time setup/RecapViewController.swift on lines 30..34
Resources/MainUI/First time setup/TimeSetupViewController.swift on lines 105..109
Resources/MainUI/First time setup/VideoFormatViewController.swift on lines 59..63
Resources/MainUI/Infos panels/CreditsViewController.swift on lines 21..25
Resources/MainUI/Infos panels/CreditsViewController.swift on lines 27..31
Resources/MainUI/Infos panels/CreditsViewController.swift on lines 33..37
Resources/MainUI/Infos panels/CreditsViewController.swift on lines 39..43
Resources/MainUI/Infos panels/HelpViewController.swift on lines 18..22
Resources/MainUI/Infos panels/HelpViewController.swift on lines 24..28
Resources/MainUI/Infos panels/HelpViewController.swift on lines 30..34
Resources/MainUI/Infos panels/HelpViewController.swift on lines 36..40
Resources/MainUI/Infos panels/InfoViewController.swift on lines 21..25
Resources/MainUI/Infos panels/InfoViewController.swift on lines 27..31
Resources/MainUI/Settings panels/AdvancedViewController.swift on lines 295..299
Resources/MainUI/Settings panels/SourcesViewController.swift on lines 116..120

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 47.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Severity
Category
Status
Source
Language