-
Notifications
You must be signed in to change notification settings - Fork 56
Fixed to work with updated DBF library (last commit Aug 2nd 2018 ca2b… #47
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
base: master
Are you sure you want to change the base?
Conversation
…59e04bddb6e7d802f70040f57e29be666b05)
This fixes the problem with wrong encoding when dbf file is read and encoding is not specified. We eg. use UTF-8, which gives correct results instead of some strange characters when non-ascii characters are used.
end | ||
|
||
@dbf = Dbf::Reader.open(@file_root + '.dbf') | ||
@dbf = Dbf::Reader.open(@file_root + '.dbf', nil, dbf_encoding) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Style/StringLiterals: Prefer double-quoted strings unless you need single quotes to avoid extra backslashes for escaping.
# Open DBF with specified encoding (it can also be nil and DBF reader | ||
# will use what it finds in header). | ||
def self.open(f, memo = nil, encoding) | ||
new(f, memo, encoding) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Layout/IndentationWidth: Use 2 (not 8) spaces for indentation.
new(f) | ||
# Open DBF with specified encoding (it can also be nil and DBF reader | ||
# will use what it finds in header). | ||
def self.open(f, memo = nil, encoding) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Layout/Tab: Tab detected.
Layout/IndentationConsistency: Inconsistent indentation detected.
Naming/UncommunicativeMethodParamName: Method parameter must be at least 3 characters long.
def self.open(f) | ||
new(f) | ||
# Open DBF with specified encoding (it can also be nil and DBF reader | ||
# will use what it finds in header). |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Layout/Tab: Tab detected.
|
||
def self.open(f) | ||
new(f) | ||
# Open DBF with specified encoding (it can also be nil and DBF reader |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Layout/Tab: Tab detected.
Do the specs pass for you, @Nazz78? I get a lot of failures, e.g.
|
@kueda I don't know. Can you please provide me with some link on how to set the specs up? |
For me I just ran |
Added proper ColumnType::Base according to updated DBF library? Works for me.