概要

ResourceSyncのPythonライブラリである「py-resourcesync」を試したので、その備忘録です。

https://github.com/resourcesync/py-resourcesync

セットアップ

gcpidyttphcyol-norneseseothuutrptcpeissn:ys/nt/caglilthub.com/resourcesync/py-resourcesync

実行

resourcelist

まず、出力用のresource_dirディレクトリを作成します。カレントディレクトリにex_resource_dirフォルダが作成されます。

r!emskoduirrce-_pdi$rre=so"uerxc_er_edsiorurce_dir"

次に以下を実行します。適宜generatorを変更して使用するようですが、以下ではEgGeneratorというサンプルのものを使用しています。

f#fmmrrrrryesssofo_t..mrmga=geoedexrmrnaRneeeeteecsmsrasruoyoa_oatu_utdutergroiro(cecrrcr)eneeses==S=yryynanE"nmctcgecy.o.Gx(_rrge_sgeenmtesineernomertaeupraatrmrroatdeeeacrtoagsttetortyoaosr(a=udryMs)_0rany.d,ctcGeieaegr__in_"ddmegiipre#rroan==rtermtoreerastRtoaeoudsrraoctuiearm__cpddeoiiSrrryt,)ncEgGenerator

結果、ex_resource_dir/ex_metadata_dirに、.well_knowncapabilitylist.xmlresourcelist_0000.xmlが作成されます。

<<?u/xrumlrlsx<<<lemrru/svtlssrueen::lrtrxslm><<l>sm:ndlr>ilrosonshcc:ns=ra>m=="ephd'"hfat1ht=btc.tt"ipa0tphl:p'p:ti/a:tt/bepywinw:=wlcww/"wiowwc.tdw.waeyi.owpx=nspwaa"gie.bmr=tneipe'eaxllsUmraieoTacmt.uFphpycr-silloc8.veime'oe.s/l?rsctmi>g.o"esomttsr/a"cg.dhwaeretmslaa/l_st-d/ekisrnrimo/tswre/nem"/sa>ropeu/sr0oc.ue9rl"ciessty_n0c0"00r.exlm=l"<u/pl"oc>
<<?u/xrumlrlsx<<<lemrru/svtlssrueen::lrtrxslm><<<l>sm:ndllr>ilroasonshacs:ns=rt>tm=="e=hmd'"hf"to1ht=2tdh.tt"0p>a0tph2:2s'p:t2/0h:t-/1=ep1w6"nw:1w-mcww/-w1doww2.05dw.w1r-:i.owTe0cnspw0s1cgie.0oT9=tne:u08'eax1r09Umra3c:5Tacm:e0aFphp4s02-sil6y:18.veZn0e'oe."c03?rsc.Z3>g.oco<5omar/bsr/pglbcgma<aeh/eb/s6ertilt6msalomda/dico6stat>d1/ety>fsra=2im_"btsdr6e/ie2m"rsca>/oepcu3/ara0pc8.aee9bl""iilslitet"nyglctiohsm=tp".l2xe0mt"le"dt=yr"pe2el0==2""2au-pp1p"1l-i2c1aTt0i0o:n1/3x:m4l6"Z"

changelist

strategy1に変更することでnew_changelist2に変更することでinc_changelistを作成することができました。

Resourcedump と Changedump

strategy3に変更することでresourcedump4に変更することでchangedumpを作成できるようですが、これらについては設定方法を十分に理解することができず、未検証です。

まとめ

ResourceSyncの実装方法を調査する上で参考になりました。

他の方の参考にもなりましたら幸いです。