Skip to content

Conversation

@xor-gate
Copy link
Owner

Initial work on tempfiles for data.tar.gz and control.tar.gz when packaging exceed RAM size.

@xor-gate xor-gate changed the title [wip] Tempfiles for data.tar.gz and control.tar.gz Tempfiles for data.tar.gz and control.tar.gz Jun 26, 2017
@xor-gate xor-gate requested a review from rikvdh June 26, 2017 18:41
@xor-gate
Copy link
Owner Author

ping @rikvdh

Repository owner deleted a comment from coveralls Jun 26, 2017
Repository owner deleted a comment from coveralls Jun 26, 2017
Repository owner deleted a comment from coveralls Jun 26, 2017
Repository owner deleted a comment from coveralls Jun 26, 2017
Repository owner deleted a comment from coveralls Jun 26, 2017
Repository owner deleted a comment from coveralls Jun 26, 2017
Repository owner deleted a comment from coveralls Jun 26, 2017
Repository owner deleted a comment from coveralls Jun 26, 2017
@coveralls
Copy link

coveralls commented Jun 26, 2017

Coverage Status

Coverage decreased (-5.8%) to 71.03% when pulling f76fb0b on tempfile into 611a9e4 on master.

@coveralls
Copy link

coveralls commented Jun 26, 2017

Coverage Status

Coverage decreased (-5.8%) to 71.03% when pulling 70aa48a on tempfile into 611a9e4 on master.

@coveralls
Copy link

coveralls commented Jun 26, 2017

Coverage Status

Coverage decreased (-7.6%) to 69.218% when pulling 92c3c96 on tempfile into 611a9e4 on master.

// SetTempDir sets the temporary directory for intermediate files. When the directory doesn't
// exist it is automaticly created. The caller is responsible for the cleanup of tempdir.
func SetTempDir(dir string) error {
if dir == "" {
Copy link
Collaborator

Choose a reason for hiding this comment

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

When the directory is emtpy you take the empty-directory as TempDir? Don't you want to get the system-wide temp-dir with os.TempDir()?

Copy link
Owner Author

Choose a reason for hiding this comment

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

empty Directory is automatic os.TempDir, see os.TempFile

control.go Outdated
c.info.maintainer,
c.info.maintainerEmail)
o += fmt.Sprintf("Installed-Size: %d\n", installedSize)
o += fmt.Sprintf("Installed-Size: %d\n", uint64(math.Floor((float64(installedSize)/1024)+0.5)))
Copy link
Collaborator

Choose a reason for hiding this comment

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

Just use math.Ceil() without the floor(x+0.5) which is also wrong.

@rikvdh rikvdh merged commit e72663d into master Jun 26, 2017
@rikvdh rikvdh deleted the tempfile branch June 26, 2017 21:07
@coveralls
Copy link

Coverage Status

Coverage decreased (-7.6%) to 69.218% when pulling 0e8d9c1 on tempfile into 611a9e4 on master.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants