Comments (20)
Hello Wanda,
Unfortunately, I am not a user of Homebrew so I won't be able to create a tap for fpart. Anyway, I would be happy to integrate it if someone provided one to me :)
Anyone interested in contributing ?
from fpart.
I can definitely give it a shot! I will research and get back to you :D
from fpart.
I created a homebrew-fpart repository, and then ran
$ brew create https://github.com/martymac/fpart/archive/fpart-1.1.0.tar.gz
to create
/usr/local/Homebrew/Library/Taps/homebrew/homebrew-core/Formula/fpart.rb
which I then copied to the repository directory:
$ cp /usr/local/Homebrew/Library/Taps/homebrew/homebrew-core/Formula/fpart.rb ./homebrew-fpart/Formula/
However, I have a few questions:
- In order to publish to the
homebrew-core
(as seen in the section on Contributing), one needs to have atest
within theFormula
; what kind of test can be done to ensure thatfpart
has been installed correctly, other than ensuring the output is equal to the help text:
$ fpart
Please specify either -n, -f or -s.
Usage: fpart [OPTIONS] -n num | -f files | -s size [FILE or DIR...]
Sort and pack files into partitions.
General options:
-h this help
-V print version
...
- I see the file generated by
brew create
has calls tocmake
commented out; shall I just delete these lines, since in thefpart
repoREADME.md
the only calls you use areautoreconf -i
,./configure
,make
, andmake install
(as root).
from fpart.
Hello Wanda,
Good news, thanks for your contribution :)
-
Maybe you can trigger a simple 'fpart -V' which displays the current version as well as build options ?
-
Yes, I presume you can, fpart does not use CMake at all
Once you have everything ready (and if you want), just tell me, I'll import your work into the contribs/package/homebrew directory.
Thanks again :)
from fpart.
Ahhhh, well I guess the issue is that in the Homebrew docs, they say:
We want tests that donβt require any user input and test the basic functionality of the application. For example foo build-foo input.foo is a good test and (despite their widespread use) foo --version and foo --help are bad tests. However, a bad test is better than no test at all.
Is there some sort of simple operation that I could perform and validate the output of other than running fpart -V
? I'm only familiar with using fpsync
that comes with fpart
(which is actually my intention for wanting to be able to install this - to have access to fpsync
).
Thank you for working through this with me! This is my first time actually contributing something to a repo, so I'm kind of pumped, not gonna lie
from fpart.
Hello Wanda,
You can use that simple one-liner :
touch "${HOME}/.fpart-test" && fpart -n 1 -y ".fpart-test" "${HOME}" 2>/dev/null | grep -q "0 (0): ${HOME}/.fpart-test"
that will create an empty file in ${HOME} and then use fpart to pack it in a single partition. That will ensure that fpart works, can crawl the filesystrem and output a partition.
Best regards,
Ganael.
from fpart.
Absolutely brilliant!! Thank you, Ganael; I'll keep you posted when I push to the homebrew-fpart
repo and the results for testing and subsequently installing fpart
using brew
!
from fpart.
Hey Ganael, I've got a quick question for you: when I try to run fpart
in the terminal as you have described, i.e.
touch "${HOME}/.fpart-test" && fpart -n 1 -y ".fpart-test" "${HOME}" 2>/dev/null | grep -q "0 (0): ${HOME}/.fpart-test"
The command hangs. I attempted to break it apart and test, and observed that
fpart -n 1 -y ".fpart-test" "${HOME}"
gives no output, despite the file .fpart-test
existing in the home directory. I thought perhaps it was because the point you were attempting to create the partition at, i.e. ${HOME}
, might be problematic, so I did mkdir ${HOME}/tmpDir
and attempted to run
fpart -n 1 -y ".fpart-test" "${HOME}/tmpDir"
The command executed, but no output was forthcoming, and ~/tmpDir
was empty.
Is there an issue because I'm not using fpart
correctly as per its usage:
Usage: fpart [OPTIONS] -n num | -f files | -s size [FILE or DIR...]
from fpart.
Hello Wanda,
Weird... You are using fpart the right way.
Can you add verbose options to see what's happening? :
$ fpart -vv -n 1 -y ".fpart-test" "${HOME}/tmpDir"
Maybe you can also try using a fixed directory first, such as /tmp instead of ${HOME}.
Hope this helps,
Regards,
Ganael.
from fpart.
Here ya go, Ganael!
$ pwd
/Users/wboyer
$ echo ${HOME}
/Users/wboyer
$ ls -lahe .fpart-test
-rw-r--r-- 1 wboyer CORP\Domain Users 0B 28 Aug 17:02 .fpart-test
$ fpart -vv -n 1 -y ".fpart-test" "${HOME}/tmpDir"
Examining filesystem...
0 file(s) found.
$ ls -lahe ~/tmpDir/
total 0
drwxr-xr-x 2 wboyer CORP\Domain Users 64B 29 Aug 09:12 .
drwxr-xr-x@ 84 wboyer CORP\Domain Users 2.6K 29 Aug 09:12 ..
0: group:everyone deny delete
So I'm not sure if it's actually creating the partition... Should I create a separate bug report and poke around at this later today?
from fpart.
Hello Wanda,
Your .fpart-test file is in "${HOME}" while you are asking fpart to work on "${HOME}/tmpDir".
Either move .fpart-test to "${HOME}/tmpDir" or start fpart that way :
$ fpart -vv -n 1 -y ".fpart-test" "${HOME}"
It should now find the .fpart-test file and display (on stdout) a single partition with that file inside.
Best regards,
Ganael.
from fpart.
Oh gosh I'm so sorry! I don't know how fpart
works - only have used your fpsync
!!! Thank you for walking me through this :D
EDIT: Works like a charm!
$ fpart -vv -n 1 -y ".fpart-test" "${HOME}/tmpDir"
Examining filesystem...
/Users/wboyer/tmpDir/.fpart-test
1 file(s) found.
Sorting entries...
Part #0: size = 0, 1 file(s)
Writing output lists...
0 (0): /Users/wboyer/tmpDir/.fpart-test
Cleaning up...
from fpart.
Great, good news :)
from fpart.
Hello Wanda,
Is everything working fine regarding that issue ? Is the homebrew package working now or do you still need help ?
Ganael.
from fpart.
Hey @martymac ! Sorry for the delay; things have been a bit crazy at work, and since the needs of the project went in another direction, I haven't taken time on my own to get this working and tested... I'll keep you posted next week if I can eke some time for this task!
from fpart.
Hello Wanda,
OK, no pb :) Thanks for the update !
Best regards,
Ganael.
from fpart.
I'll close that bur report for now, feel free to re-open it if necessary.
from fpart.
FYI, I took a stab at this: Homebrew/homebrew-core#62573.
from fpart.
Hello @benstiglitz,
Good news, thanks!
from fpart.
Thanks again for your contribution!
from fpart.
Related Issues (20)
- Look for MAIL_BIN in fpsync only if OPT_MAIL is set HOT 2
- "please supply and absolute path" when it already is HOT 2
- Getting 'grep' and 'ls' errors on fpsync HOT 25
- FPSync not passing exclude options to rsync HOT 4
- Feature request: Transmitted data size? HOT 4
- Expected Behavior? HOT 2
- Hidden directory is not being excluded HOT 7
- Currently transferred data measurement? HOT 4
- List of files transferred & their sizes? HOT 2
- fpsync: What are the "default arguments supplied to rsync"? HOT 1
- 1st partition has a different path than others. HOT 6
- Throttle fpsync transfer rate HOT 1
- Add multi-thread support while crawling the file system HOT 3
- Single files support HOT 5
- fpart: incomplete partitions on sshfs HOT 9
- Meaning of 0th partition file in different modes is confusing HOT 23
- Format change for '-S' output HOT 7
- sorting with mathematical function HOT 1
- Problem running fpsync with GNU parallel or in background from the shell, the process will go in STOP state HOT 11
- fpart/fsync is slowly when reading files names from S3 or similiar object file system HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
π Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. πππ
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google β€οΈ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from fpart.