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

Fix duplicate import #1431

Merged
merged 2 commits into from
Aug 19, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 1 addition & 3 deletions src/moepkg/editorstatus.nim
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import strutils, terminal, os, strformat, tables, times, heapqueue, deques,
times, options
options
import syntax/highlite
import gapbuffer, editorview, ui, unicodeext, highlight, fileutils,
undoredostack, window, color, settings, statusline, bufferstatus, cursor,
Expand Down Expand Up @@ -1179,8 +1179,6 @@ proc autoSave(status: var Editorstatus) =
status.messageLog)
status.bufStatus[index].lastSaveTime = now()

from settings import TomlError, loadSettingFile

proc loadConfigurationFile*(status: var EditorStatus) =
status.settings =
try:
Expand Down
2 changes: 1 addition & 1 deletion src/moepkg/editorview.nim
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import deques, strutils, math, strformat
import gapbuffer, ui, unicodeext, highlight, independentutils, color, settings,
import gapbuffer, ui, unicodeext, independentutils, color, settings,
bufferstatus, highlight

type EditorView* = object
Expand Down
3 changes: 1 addition & 2 deletions src/moepkg/filermode.nim
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
import os, terminal, strutils, unicodeext, times, algorithm, sequtils, options
import editorstatus, ui, fileutils, editorview, gapbuffer, highlight,
commandview, highlight, window, color, bufferstatus, settings, messages,
commandline
commandview, window, color, bufferstatus, settings, messages, commandline

type PathInfo = tuple[kind: PathComponent,
path: string,
Expand Down
1 change: 0 additions & 1 deletion src/moepkg/normalmode.nim
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
from strutils import parseInt
import terminal, times, strutils
import editorstatus, ui, gapbuffer, unicodeext, fileutils, undoredostack,
window, movement, editor, search, bufferstatus, quickrun,
Expand Down
6 changes: 0 additions & 6 deletions src/moepkg/settings.nim
Original file line number Diff line number Diff line change
@@ -1,12 +1,6 @@
import parsetoml, os, json, macros, times, options, strformat, osproc, strutils
from strutils import parseEnum, endsWith, parseInt
export TomlError

when (NimMajor, NimMinor, NimPatch) > (1, 3, 0):
# This addresses a breaking change in https://github.com/nim-lang/Nim/pull/14046.
from strutils import nimIdentNormalize
export strutils.nimIdentNormalize

import ui, color, unicodeext, highlight, platform, independentutils

type DebugWindowNodeSettings* = object
Expand Down
2 changes: 1 addition & 1 deletion src/moepkg/suggestionwindow.nim
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import critbits, unicode, sugar, options, sequtils, unicode
import critbits, sugar, options, sequtils, unicode
import ui, window, generalautocomplete, bufferstatus, gapbuffer, color,
editorstatus

Expand Down
4 changes: 1 addition & 3 deletions src/moepkg/unicodeext.nim
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import unicode, strutils, sequtils, strutils, strformat
import unicode, sequtils, strutils, strformat, os
import unicodedb/widths
import gapbuffer
export unicode
Expand Down Expand Up @@ -377,7 +377,6 @@ proc toggleCase*(ch: Rune): Rune =
result = result.toUpper()
return result

from os import `/`
proc `/`*(runes1, runes2: seq[Rune]): seq[Rune] {.inline.} =
toRunes($runes1 / $runes2)

Expand Down Expand Up @@ -424,6 +423,5 @@ proc encodeUTF8*(r: Rune): seq[uint32] =
result.add mbLead or i shl 6
result.add mbLead or i and mbMask

from os import absolutePath
proc absolutePath*(runes: seq[Rune]): seq[Rune] {.inline.} =
absolutePath($runes).ru